Home » Developer & Programmer » Forms » LOV and Tab
LOV and Tab [message #631740] Mon, 19 January 2015 05:51 Go to next message
sanodani
Messages: 98
Registered: October 2014
Member
Hallo ..
can anybody give some hints or help me regarding my Problem? Please.

my Problem is:

I have master-Detail block (forms) and have two Detail block with two tab convases. Master block has a filed called invoice no. ( which links to the other two blocks)
the one Detail Block Shows the Detail of all articles and the other Shows the Detail of Shops.
and i have set LOV in invoice no. field.
when i run with normal (F11 or Query Execute) then it works fine and Shows the Output in both Tabs, but when i choose the Value in Invoice field from LOV, will Display just in first tab not in the second Tab,
can anyone help me, how can i Display the related Information in the second tab too? or which Trigger should i Need to write?

thanking you all in advance.
regards,
Re: LOV and Tab [message #631747 is a reply to message #631740] Mon, 19 January 2015 07:08 Go to previous messageGo to next message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Quote:

but when i choose the Value in Invoice field from LOV, will Display just in first tab not in the second Tab

How exactly do you do that? Do you first enter query, select value from a LoV, and execute query? If not, you should have.
Re: LOV and Tab [message #631752 is a reply to message #631747] Mon, 19 January 2015 08:24 Go to previous messageGo to next message
sanodani
Messages: 98
Registered: October 2014
Member
i mean, i would first select value from LOV then it will execute the records in the first tab where i can see article Detail but it will not Show any records in tab2, where it shouls Show Shops Detail.
can i do this with pre-query ??

go_block('block_name');
execute_query;
Re: LOV and Tab [message #631768 is a reply to message #631752] Mon, 19 January 2015 10:35 Go to previous messageGo to next message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Set data block's ONETIME_WHERE with SET_BLOCK_PROPERTY, then execute query.
Re: LOV and Tab [message #631809 is a reply to message #631768] Tue, 20 January 2015 01:15 Go to previous messageGo to next message
sanodani
Messages: 98
Registered: October 2014
Member
Hi..

Thankx for your Suggestion. Well, I did the same as you told me, it Shows records in my second tab too but, i see the error at the bottom.
'FRM-40737: Illigal restricted procedure EXECUTE_QUERY in PRE_QUERY trigger'

I have written following code in my pre_query Trigger, i don't whether i have written in wrong Trigger..

set_block_property('DETAIL_BLK1', ONETIME_WHERE, 'INVOICE = :MASTER_BLK.INVOICE');
go_block('DETAIL_BLk1');
execute_query;


can you please help me ?
thankyou
regards,
Re: LOV and Tab [message #631847 is a reply to message #631809] Tue, 20 January 2015 17:16 Go to previous messageGo to next message
CraigB
Messages: 386
Registered: August 2014
Location: Utah, USA
Senior Member
sanodani wrote on Mon, 19 January 2015 07:24
i mean, i would first select value from LOV then it will execute the records in the first tab where i can see article Detail but it will not Show any records in tab2, where it shouls Show Shops Detail.
can i do this with pre-query ??

go_block('block_name');
execute_query;

How are you putting your form into Query Mode (programmatically or via F-Key)? If you are using the F-Keys, then you can emulate this in your Key-ListVal trigger when you display your LOV. For Example:
-- Sample Key-ListVal Trigger
-- Code is untested
-- --------------------------
BEGIN
  Enter_Query;
  List_Values;
  Execute_Query;
END;

If you are doing this programmatically, please show us your code.

Craig...

[Updated on: Tue, 20 January 2015 17:19]

Report message to a moderator

Re: LOV and Tab [message #631865 is a reply to message #631847] Wed, 21 January 2015 01:16 Go to previous message
sanodani
Messages: 98
Registered: October 2014
Member
Hallo Craig,
thankx a lot for your Suggestion.
I have written Key-Listval Trigger in Block Level as you have mentioned and now it works without showing any error. Smile
As before i have written pre-query Trigger in block Level with the code as i have mentioned above in my previous post.
thanx once again

regards.
Previous Topic: Problem with inserting in the a trigger
Next Topic: [FORMS10g] : Get Windows logged User?
Goto Forum:
  


Current Time: Thu Apr 25 02:49:01 CDT 2024