Normal Topic Moving to a new record in a file. (Read 554 times)
NHUser
Full Member
***
Offline



Posts: 320
Location: Amherst, NH
Joined: Aug 2nd, 2010
Moving to a new record in a file.
Jan 22nd, 2016 at 1:32pm
Print Post Print Post  
I would like to move from one record to another within the same file without going back to the retrieve spec. 

I was thinking I could put a command button on my form with a command to move to the different record based on the information in an element in the current record.

Is this possible?
  
Back to top
 
IP Logged
 
Carl Underwood
Senior Member
Members
*****
Offline



Posts: 1351
Location: New Hampshire
Joined: Mar 11th, 2003
Re: Moving to a new record in a file.
Reply #1 - Feb 22nd, 2016 at 3:01pm
Print Post Print Post  
Even though you don't want to go back to the retrieve spec, you can automate this with SBasic in order to get to another result set. This can be done by using ClientLocalValue to store indicators that SBasic can use.

You'd have a command button on the form that sets a ClientLocalValue, then navigates to the retrieve spec via @SelectTreeItem. In the OnRetreiveSpecOpen event, you determine if the ClientLocalValue has been set (which is has in this case), set your retrieve specs to what you need to find the target record (maybe with info stored in another ClientLocalValue), then use @SelectTreeItem("Search Menu!Search Commands!Retrieve New Results (F10)") to open the new result set.
  


Carl Underwood
CDU Computer Consulting LLC
Epsom, New Hampshire
Back to top
IP Logged