[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now


Oracle Forms 10g: How to avoid record navigation?

Posted on 2011-04-21
Medium Priority
Last Modified: 2012-05-11
How to avoid record navigation in Oracle Forms 10g?

My form has 5 blocks: 3 Control-Blocks and 2 Blocks where the user can navigate through the records.

The user must remain in the same record when the focus is on the first 3 Control Blocks. Rules:

1) If he presses the key (Page Down) to navigate to the next record, nothing happens.

2) If he presses the key (Page Up) to navigate to the previous record, nothing happens.

3) If he presses the button using the mouse to navigate to the next record, nothing happens.

4) If he presses the button using the mouse to navigate to the previous record, nothing happens.

5) If he presses the button using the mouse to insert or delete a record, nothing happens.


p.s.: Please assist my other questions.
Question by:jocafi
LVL 21

Accepted Solution

flow01 earned 2000 total points
ID: 35448400
1 find out what logical trigger in forms corresponds to your  "Page down"   (for example key-nxtblk) .  
    1a  Create such a trigger on all 3 control-block and code
             -- message('you hit key-nxtblk');  -- to check what key trigger you need
             null; -- disable normal functioning of the key
     1b Create such a trigger on forms level and check :system.trigger_block  in (ctrl1,ctrl2,ctrl3) for a conditonal disa
           if :system.trigger_block in ('CTRL1', ..) THEN
                null; -- disable normal functioning of the key
               NEXT_BLOCK;  -- use the build-in that corresponds to normal key-behaviour
           end if;
2 same method / other keys/triggers and build-in
3,4,5 check the when-button-pressed trigger of the button : change it to prevent what you don't want
    if you can't figger it out, show an example of the code

When the focus is in one of the control-blocks what should the user do to be able to navigate ?


Author Closing Comment

ID: 35450762
Many Thanks, flow01. It works !

I put the code below (adjusting the code for each key) in the triggers KEY-NXTREC, KEY-PRVREC, KEY-DOWN, KEY-UP:

 -- normal DB blocks
 if :system.trigger_block in ('COLABORADORES','PARTICIPANTES') THEN
          -- control blocks
         -- disable normal functioning of the key
 end if;

I adjusted the code above in other triggers too.
LVL 35

Expert Comment

by:Mark Geerlings
ID: 35454962
That may confuse the users (leaving them to wonder why the navigation keys work in some blocks, but not others), but it should work.  I would rather see the trigger not just do "null:" when you want to disable it, but display an alert to indicate that the requested navigation event is not available in this block.

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this post we will learn how to make Android Gesture Tutorial and give different functionality whenever a user Touch or Scroll android screen.
This article will show how Aten was able to supply easy management and control for Artear's video walls and wide range display configurations of their newsroom.
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.
Six Sigma Control Plans

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question