redsoxlost
redsoxlost

Reputation: 1235

Oracle Forms - Identify which button was pressed

I have an Oracle form, which when starts has the following activated field. 1. 2 text Item + 2 push button working as LOV button 2. One Button (cancel)

Now for simplicity lets call the text time as text_1 , text_2 Now user has an option to enter any value in text_1 and either press TAB to move to next text item or use mouse pointer to move the cursor to text_2 item OR can press cancel button.

I want to know if the user has pressed TAB or used mouse to press cancel button. Please let me know in case the question is not clear to you.

Upvotes: 0

Views: 2677

Answers (2)

Shamim Ahmed
Shamim Ahmed

Reputation: 19

if user presses tab key, forms generate KEY-NEXT-ITEM trigger and post-text-item trigger. Again if user move the cursor using mouse then it only generate post-text-item trigger. If any text item has to fire two trigger then key-next-item fires first.

You can also get triggered item using :SYSTEM.TRIGGER_ITEM.

Thanks Shamim Ahmed.

Upvotes: 0

Petr Pribyl
Petr Pribyl

Reputation: 3575

if user presses tab key, forms generate KEY-NEXT-ITEM trigger. You can type your code there and manage this event. If users presses a button, forms generates WHEN-BUTTON-PRESSED.

Is this right answer to your question? If not, provide a use case, how will programm work from user point of view.

Upvotes: 0

Related Questions