Form view

endri81

Registered User.
Local time
Today, 05:56
Joined
Jul 5, 2010
Messages
121
How to make textbox show some text in form view?
I mean if we have form with birthday textbox in formview before data is entered there is "birthday" word in it
 
That is a pain in the butt to manage. It is not easy and requires a lot more code than it is worth. You would need code in the Got Focus event to remove the word, in the Lost Focus you would need to check to see if it was filled with a date and then if not replace it with Birthday again (perhaps, perhaps not depending on how you want it to work). And then you would need code in the Before Update event of the form to remove that word if it was still there.

If you do this with any more of the controls then it quickly becomes a bit of a management nightmare. Just an FYI.
 
Oh, AND if it is bound to a date field you can't have it show that anyway because it won't be the correct datatype. You would need to either store your date as text or use a second textbox (Unbound) which hides itself when clicked in and sets the focus to the correct one and then upon exit, if there isn't a date in the 2nd text box, unhides it again.
 

Users who are viewing this thread

Back
Top Bottom