Reputation: 6185
I have assigned a default value to a label box in Property Sheet/data/default value. When I create a new entry via the form, the default value shows up but then I have to select it and delete it in order to enter the correct value.
Is there a way to automatically make the default value vanish when I enter the field? (like on this page where you are ask for you email : http://www.boogiejack.com/form_trick3.html)
I am using the default value to display a hint about what data should be enter in this label. I will never keep the default value in my actual database. My default value is not a permanent value.
I though about adding in virtual basic something like :
IF text = default value THEN delete
but I am a newbie and can figuring out how to do it or even if this is the correct way of doing it.
Thanks!
Upvotes: 1
Views: 5135
Reputation: 123654
Remove the Default
property (Data tab) and use the Format
property (Format tab) to specify text that will be displayed when the Text Box contains a Null value. For Text fields, there are two parts to the Format
property string:
format_to_use_when_not_null;format_to_use_when_null
so you could use something like this
@;"(Please enter something here.)"
That text will appear until the user clicks inside the Text Box (or tabs into it and starts typing).
Upvotes: 3