Home » Developer & Programmer » Forms » calling a form from another form
calling a form from another form [message #172454] Tue, 16 May 2006 10:04 Go to next message
ramanajv1968
Messages: 168
Registered: December 2005
Location: HYDERABAD
Senior Member
Hi,

U r help is greatly appreciated.

Can any one help on this problem.

I have two forms in two different modules.
Like Main_form in one module.
Secondly I have another form called Login_Form.
In the main_form I have a Create Login button. When I press this button , it should show the form called Login_Form.

I have written the code
in the main_form of create_login under trigger called when_button_pressed.


call_form('Login_Form',display);

But it is not working.
can any one please help on this.

Thanks & Regards,
Re: calling a form from another form [message #172490 is a reply to message #172454] Tue, 16 May 2006 19:01 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Have you placed the name of the directory in which you are doing your work into the registry entry FORMSxx_PATH? Which version of forms are you using?

Search this forum for 'FORMS _PATH'.

David
Re:when new form displays , calling form should be automatically closed [message #172535 is a reply to message #172490] Wed, 17 May 2006 02:31 Go to previous messageGo to next message
ramanajv1968
Messages: 168
Registered: December 2005
Location: HYDERABAD
Senior Member
Thanks,
for u r useful information with that i solved my problem.
But i have one more query . when i call a form say FORM B from another form say FORM A . FORM B is displaying but FORM A is not closing automatically.

In nutshell ,

when i call a form from another form calling form should be closed automatically and it should be display only new form.

Any help in this regard will be appreciated,
ramana
Re:when new form displays , calling form should be automatically closed [message #172553 is a reply to message #172535] Wed, 17 May 2006 03:19 Go to previous messageGo to next message
gacki
Messages: 33
Registered: May 2006
Location: Dueren, NRW, Germany
Member
The second parameter of call_form built-in takes either HIDE or NO_HIDE, which means to either hide the calling form or not.

Gerald
Re:when new form displays , calling form should be automatically closed [message #172581 is a reply to message #172553] Wed, 17 May 2006 04:36 Go to previous messageGo to next message
ramanajv1968
Messages: 168
Registered: December 2005
Location: HYDERABAD
Senior Member
hi,

but it is only hiding the calling form say FORM A . when i closed the called form say FORM B ,then i agin able to see the main form ie FORM A. My requirement is when i call FORM B from FORM A FORM A Should be automatically closed.

Thanks and Regards,
ramana
Re:when new form displays , calling form should be automatically closed [message #172593 is a reply to message #172581] Wed, 17 May 2006 05:10 Go to previous messageGo to next message
gacki
Messages: 33
Registered: May 2006
Location: Dueren, NRW, Germany
Member
In that case use new_form instead of call_form (see Online Help).

Gerald
Re: calling a form from another form [message #172962 is a reply to message #172454] Thu, 18 May 2006 14:29 Go to previous messageGo to next message
ramanajv1968
Messages: 168
Registered: December 2005
Location: HYDERABAD
Senior Member
Hi ,

I still have the same problem. I am creating a login form
when i pressed SIGN IN Button ,It must check whether the user exist in the table or not.
If the user is exist then it should be display a new form.So for this requirement, I wrote the
following trigger on SIGn Button as when_button_pressed

------------The code is as follows----------------

select 'x' into :global.dummy from sw_login
where swusername = :sw_login.swusername and
swpassword = :sw_login.swpassword;
pause;
call_form('C:\Madhav\Oracle_forms_CD_DOC\BookCodes\Project\Banking_System\6i\Forms\CTE_MADHAV\cte_COMPANY',hide,no_replace,no_query_o nly,'X');

exception
when no_data_found then
message('Username and/or password are incorrect');
raise form_trigger_failure;
-----------------------------------------------------------
When i pressed SIGN Button with existing username,password I am successfully moving to next form.
But when i closed this second form , I am again seeing the Previous login form.
In nutshell when the control is shifted to the new form it should not display the previous form.

Please if possible give me the code .Its very very urgent.



Hoping to find solution soon.


Thanks ,
ramana
Re: calling a form from another form [message #172992 is a reply to message #172962] Thu, 18 May 2006 19:18 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Quote:

In that case use new_form instead of call_form
Which part of Gerald's reply do you not understand or are unable to implement?

David
Re: calling a form from another form [message #173142 is a reply to message #172992] Fri, 19 May 2006 11:03 Go to previous message
ramanajv1968
Messages: 168
Registered: December 2005
Location: HYDERABAD
Senior Member
Sir,
Thank you so much for your prompt reply.
I am able to resolve my problem.
Previous Topic: how use input box
Next Topic: data not inserting into cursor
Goto Forum:
  


Current Time: Fri Sep 20 10:33:39 CDT 2024