control enter key

Lerebours, Jose Jose.Lerebours at EagleGL.com
Wed Dec 1 11:19:05 PST 2004


> 
> I have a client who has made a unique request.  He would like me to 
> "disable: the enter key when a user is accessing record using 
> an index.
> A user uses an index to locate a record. When the enter key 
> is pressed 
> filepro moves that user to the next record. The same action 
> can be done 
> by pressing the up or down arrow keys.
> 
> I don't see any downside to this, but I was wondering what 
> would be the 
> best way to do this?
> 
> I have found that the @SK value is "ENTR" at the @ENTSEL label, but a 
> test for this value does not stop the action.
> 
> Any suggestions?
> 

I have something in place where based on user profile, he/she
can only work with one record, get out and go back in for next
record (this was done after users were pressing the ENTER key
and updating the wrong records)

My solution was pretty simple and it does not check for @sk but
rather @rn.  The moment @entsel is hit for the first time, a
variable is set to hold @rn.  Once this variable is set, @entsel
checks @sn against variable and if different, a lookup - is 
performed to return user back to original record.

It worked pretty well as the problem we were having went away!

That said, this may or may not be what you are looking for as
it does not check for @sk.  As you mentioned what if user uses
Up/Down arrow keys?    What if user presses  B and then ENTER
after scrolling Up/Down the browse page?  What if user enters
using BROWSE ON via the IUA menu?

I asked myself all of these questions and since I worked based
on the record number, things worked out OK.

Good luck!


Jose Lerebours





More information about the Filepro-list mailing list