Full Version: Date feild of form
UtterAccess Discussion Forums > Microsoft® Access > Access Forms
CHKarcher
When clicking onto a Date feild on the form - what is the code for on GetFocus to have the cusor go to the beginning of the date feild?

thanks

steve
theDBguy
I believe it's:

Me.NameOfControl.SelStart = 0

HTH
CHKarcher
Didn't work - maybe if there was a way that could highlight the entire feild like when you tab to it

steve
CHKarcher
I guess what i am looking for is like when you tab to the feild it highlights the entire feild - where as when you click on to the feild it puts the cusor in the date feild where you clicked it.


Thanks
steve
Jack Cowley
Hmmm. When I tab into a date control that has data the entire date is highlighted. Wherever I place the cursor in the control and click that is where the cursor stays. Am I missing something?

Jack

PS. Howdy TheDBGuy....
CHKarcher
opps - SelStart = 0 does work

thanks
steve
theDBguy
Glad you got it to work! Good luck.
theDBguy
I'm fine Jack, thanks for asking. Hope you're fine too!
Jack Cowley
I'm 'fine as wine' thank you very much!!! Glad to hear you are doing well too....

Jack
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.