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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Key Behavior on Fields

Status
Not open for further replies.

kennedymr2

Programmer
May 23, 2001
594
AU
I need to have the behavoir of the key on entering a field work differently on several fields.

ie. On a Date Field , have the cursor goto the end of the field.

On a Numeric field, which say defaults to 0 (zero), have the field highlighted, so when entering an amount, the zero is overwritten. ie. you do not need to backspace to get rid of the zero, before entering an amount.
--
I have found in Tools,Options there is a key behavoir, BUT this applies to all forms etc.

I need to control a seperate field if i need to.

Appreciate any help
 
It seems to me the easiest thing to do is set the Option for the Database for Behavior entering field to Select Entire Field. That will take care of the Default value. Then in the date field, set the OnFocus event to
ControlName.SelStart = Len(ControlName)+1

That should do it.

Paul
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top