Normal Topic Navigation (Read 1993 times)
nateboone
Junior Member
**
Offline



Posts: 54
Joined: Dec 19th, 2006
Navigation
Jan 5th, 2007 at 2:34am
Print Post Print Post  
Is there a Navigation option that is softer than Goto or the Navigation order?  I'm thinking of navigation that for instance would skip a field that would otherwise be next, but would allow the user to go back up into that field by pressing the up key.  Or what about a navigation option that would be invoked by pressing "Enter" or "Tab" but arrow keys wouldn't invoke it?
  
Back to top
 
IP Logged
 
Hammer
YaBB Administrator
Lanticans
*****
Offline


Fire bad. Tree pretty.

Posts: 3436
Location: Ohio
Joined: Nov 22nd, 2002
Re:  Navigation
Reply #1 - Jan 5th, 2007 at 3:02am
Print Post Print Post  
GoTo only exists for Q&A comaptibility. Use ThrowFocus instead.

As to being "softer", that depends on how you use it and what event triggers it. To skip over an element, yet allow the user to back to it, or click in it, put the ThrowFocus in the On Element Exit event of the preceding element.

Depending on what you are doing, the ReadOnly and Visibility commands may also be useful in this kind of situation.
  

- Hammer
The plural of anecdote is not data.
Back to top
IP Logged
 
Carl Underwood
Senior Member
Members
*****
Offline



Posts: 1350
Location: New Hampshire
Joined: Mar 11th, 2003
Re:  Navigation
Reply #2 - Jan 5th, 2007 at 3:19am
Print Post Print Post  
Actually, I use Navigation Order for that purpose myself. It works out quite well for me.

Make the element that you want to skip, the last (or close to the last) in the list. That way, when you are navigating normally, it is skipped over; but you can still get to it at any time by clicking on it with the mouse.

You should also place a ThrowFocus() in the On Element Exit event of the 'skipped' element (preferably sending the cursor to the next logical location). This will give a normal feel to the flow of navigation when leaving that skipped element.
  


Carl Underwood
CDU Computer Consulting LLC
Epsom, New Hampshire
Back to top
IP Logged
 
nateboone
Junior Member
**
Offline



Posts: 54
Joined: Dec 19th, 2006
Re:  Navigation
Reply #3 - Jan 5th, 2007 at 8:15pm
Print Post Print Post  
hmmm...

This is the situation, I have the following fields:

Surname
Full Name
Extra Address (Prints first, if main address isn't enough)
Address
City, St, Zip, etc.

ThrowFocus in Full Name "On Element Exit" to Address allows me to go back to Extra Address if need be, but locks me out of ever getting back to Surname except for using the mouse.

I think I am half-way pleased with putting the ThrowFocus in my "On Element Change" event, so that this navigation takes place when I'm adding to the database, but still allows me free reign afterwards to get back to Surname, etc. since I'm only adding the address once.  Can you guys think of any other options?
  
Back to top
 
IP Logged
 
Bob_Hansen
Senior Member
Members
*****
Offline


WOW, They have the Internet
on computers now!

Posts: 1861
Location: Salem, NH
Joined: Nov 24th, 2002
Re:  Navigation
Reply #4 - Jan 5th, 2007 at 10:27pm
Print Post Print Post  
I am a bit confused about what you want to do. 
How do you want to get to the Surname withought using the mouse?  //  From Where?  When?  // Under what circumstances?

Maybe if you explain how you want this to work for all of the elements.

Are you hoping to skip over the elements if they are already filled or if the record already exists?
Are you hoping to use Shift-Tab to move backwards through the tabs?
Are they laid out in the sequence that you have them listed?
Does the Navigation Order list Sequence match this layout or how is it different?

As a general rule, the Tab would go from Top Left, across to the right, then down and go left to right again to the elements based on their X,Y position on the form.  This can be changed by using the Navigation Order.  No navigation commands are usually needed to force the tab sequencing with these tools.  But you may have some exceptions.

If that is not the order that you want, then you should put a Throw Focus command in the OnEntry section of the next natural element position and in the OnExit section of the element you are leaving.  And these ThrowFocus commands can all be controlled by using conditional statements, like If @IsBlank(element) or IF @ADD, or other similar conditions.

Again, an explanation of what "abnormal" order you are trying to do, will help us to help you.
  



Bob Hansen
Sesame Database Manager Professional
Sensible Solutions Inc.
Salem, NH
603-898-8223
Skype ID = sensiblesolutions
Back to top
IP Logged
 
nateboone
Junior Member
**
Offline



Posts: 54
Joined: Dec 19th, 2006
Re:  Navigation
Reply #5 - Jan 6th, 2007 at 11:19pm
Print Post Print Post  
The previous fields mentioned are in the same Navigation Order, and are fields stacked on top of each other.  In normal Navigation, I'm looking to skip the Extra Address field, but also want to be able to access it by moving back up from the Address field (hitting the up key) if I need to add to it (10% of records added).

If I have ThrowFocus(Extra Address) in the "On Element Exit" field of Full Name, this will move from Full Name to Extra Address every time, even if I'm trying to move up to Surname.  I can use the mouse to override this obviously, but its an inconvenience.

If I simply put Extra Address at the end of the Navigation Order, this solves the above problem but creates a similar new one: I can freely get back to Surname from Full Name, but I need to either move through all the fields of my database or click the Extra Address field with my mouse to get to Extra Address, which is similar to what I'm encountering above.

I'm looking for a combination of the two above situations somehow (normal navigation from Full Name goes to Address but can return to Surname as the navigation order situation offers, but also the option to return to Extra Address from Address if need be)...  Is the main problem my own laziness in not wanting to use the mouse?  Smiley

Right now I'm half getting what I want by making this throw focus an "On Element Change" event, since most of my desire for this Navigation takes place when adding records, and still allows me to get back to surname when I'm just passing throught the field.  @Add is also a good idea, and has somewhat of a similar result.

Can you elaborate more on why you would put a ThrowFocus Command on the On Entry section of the element you are wishing to go to?

Thanks...

  
Back to top
 
IP Logged
 
Bob_Hansen
Senior Member
Members
*****
Offline


WOW, They have the Internet
on computers now!

Posts: 1861
Location: Salem, NH
Joined: Nov 24th, 2002
Re:  Navigation
Reply #6 - Jan 7th, 2007 at 1:02am
Print Post Print Post  
Here is an untested thought......

You could put a check box in same location as Extra Address with default = NO.
If checkbox is changed to YES, then check box becomes invisible, and Extra Address becomes visible.
If ExtraAddress = blank, then check box becomes visible, checkbox = NO and Extra Address becomes invisible.
This would allow you to pass from Surname to check box to Address, and  back up again, just using up/Down arrows.

Remove the ThrowFocus(Address) from Surname.
Would need to add programming to the CheckBox|OnExit and to the ExtraAddress|OnExit sections to check values.

It's not a total skp, but only one key press vs. switching to mouse.  Allows for smooth keyboard only navigation.
  



Bob Hansen
Sesame Database Manager Professional
Sensible Solutions Inc.
Salem, NH
603-898-8223
Skype ID = sensiblesolutions
Back to top
IP Logged