Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

boldTable display question

Status
Not open for further replies.

jackie1948

Programmer
Jan 25, 2002
78
US
I have a form with a name field(last,first,MI)after entering you then select the button to display the entire file in alpha order. My question is how do I get the table to go to the first entry of the last name.
example: name field: smith john M
When selecting the button i want my cursor go to the first 'smith' in my table.

Before you guys come up with your accurate advice I want to say thanks for being out ther in cyber space, I could not make it without you.
[smile]
 
jackie1948

If you want a simple workaround, have four fields in your cursor/table

firstname
initials
surname
fullname

REPL fullname WITH ALLT(surname) + [ ] + ALLT(firstname) + [ ] + ALLT(initial)

To index to achieve what you are looking for

INDEX ON ALLT(surname) + ALLT(firstname) + ALLT(initials) TAG fullname


Not sophisticated but would do the trick HTH

Chris [pc2]
 
HI Jackie,

If you have the table indexed on the field.. name.. which is a combination of last+first+M name...

Now you have three text boxes Text1+Text2+Text3...

Along with your SET command codes.. add this also..
SET NEAR ON

In the lostFocusEvent of Text1.. put the code..
SEEK Text1.Value

This will place the record pointer at the nearest search point.

In the lostFocusEvent of Text2.. put the code..
SEEK Text1.Value+Text2.Value

and in the final button..
SEEK Text1.Value+Text2.Value+Text3.Value

Hope this helps you :)

ramani :)
(Subramanian.G),FoxAcc, ramani_g@yahoo.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top