Home » Developer & Programmer » Forms » Issue with Find button in Custom built Query Find form (Oracle 10g forms )
Issue with Find button in Custom built Query Find form [message #604738] Fri, 03 January 2014 10:40 Go to next message
megha2525
Messages: 62
Registered: June 2012
Location: columbus
Member
Hi All,

I have an issue using the find button in a custom built query find form.
The form has a control block with start date, end date and find button .
Then there is a Master block and detail block.
The very first time I open the form, enter the start date , end date and click find button : I get a record and if I press down arrow key to see subsequent records; I get a message saying "You cannot create records here" . Then I again have to hit the find button , this time when I press the down arrow key I can see the subsequent records.
Here is the code for the find button.

go_block('Master BLOCK_NAME');
clear_block(no_validate);
Execute_Query;


This issue happens only for the first time when I open the form.
Also, I do not have a query_find trigger at the form level.
Please let me know how can I resolve this issue.

Thanks
Megha
Re: Issue with Find button in Custom built Query Find form [message #604746 is a reply to message #604738] Fri, 03 January 2014 12:43 Go to previous messageGo to next message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Run the form in debug mode; it'll show you which trigger is responsible for a message you get. You might be able to fix it, then.
Re: Issue with Find button in Custom built Query Find form [message #604748 is a reply to message #604746] Fri, 03 January 2014 13:31 Go to previous messageGo to next message
megha2525
Messages: 62
Registered: June 2012
Location: columbus
Member
Hi Littlefoot,

Unfortunately , I am unable to run the form in debug mode even after I did the start OC4J Instance. Every time I click on Debug -> Debug Module , forms builder open up a browser window that crashes.
Please let me know how can I run the form in debug mode.

Thanks
Megha
Re: Issue with Find button in Custom built Query Find form [message #604750 is a reply to message #604748] Fri, 03 January 2014 13:38 Go to previous messageGo to next message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
You have to enable debugging. For example, open WHEN-BUTTON-PRESSED trigger for the "Find" button, right-click left margin (gray area, left of trigger editor window, next to the first statement (which is GO_BLOCK in your case)) and set the breakpoint. Then run the form in debug mode (there are two green buttons in Forms toolbar; one runs the form "normally", another one in debug mode) and follow its execution.
Re: Issue with Find button in Custom built Query Find form [message #604751 is a reply to message #604750] Fri, 03 January 2014 13:56 Go to previous messageGo to next message
megha2525
Messages: 62
Registered: June 2012
Location: columbus
Member
Hi Littlefoot,

I inserted a Breakpoint on the first statement and Clicked Run Form Debug ( green button ) ; a new browser windows opens and crashes.

Thanks
Megha

[Updated on: Fri, 03 January 2014 13:56]

Report message to a moderator

Re: Issue with Find button in Custom built Query Find form [message #604753 is a reply to message #604751] Fri, 03 January 2014 13:59 Go to previous messageGo to next message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
I don't know why it crashes ...

Anyway: as of the problem you have, what happens if you modify the "Find" button's trigger so that it looks like this:
go_block('Master BLOCK_NAME');
-- clear_block(no_validate);     --> commented, so that it doesn't execute at all
Execute_Query;
Re: Issue with Find button in Custom built Query Find form [message #604754 is a reply to message #604753] Fri, 03 January 2014 14:04 Go to previous messageGo to next message
megha2525
Messages: 62
Registered: June 2012
Location: columbus
Member
Hi Littlefoot,

Commenting the clear_block(no_validate) did not make any difference.

Thanks
Megha
Re: Issue with Find button in Custom built Query Find form [message #604755 is a reply to message #604754] Fri, 03 January 2014 14:29 Go to previous messageGo to next message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Is there any (block level) trigger on either master or detail block? If so, which ones and what do they do?
Re: Issue with Find button in Custom built Query Find form [message #604758 is a reply to message #604755] Fri, 03 January 2014 15:41 Go to previous messageGo to next message
megha2525
Messages: 62
Registered: June 2012
Location: columbus
Member
Thank you Littlefoot for helping me fix this issue.
I had a pre query trigger at the master block level that would set the focus to the first item on the master block. So, when the execute query runs , its fetching a record based on that id. I have removed the prequery trigger and the form works as expected.

Thanks again
Megha
Re: Issue with Find button in Custom built Query Find form [message #604816 is a reply to message #604758] Sat, 04 January 2014 05:30 Go to previous message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Fine; I'm glad you solved the problem.
Previous Topic: Group wise total of Block in oracle form
Next Topic: connection issue between oracle db11g and oracle forms builder 10g
Goto Forum:
  


Current Time: Thu Apr 25 11:53:06 CDT 2024