View Full Version : Defult Value In Textbox


redblaze
02-06-2002, 11:23 AM
hi, does anybody know how to set the defult value of a textbox so that when you open the form the text box is completely empty? because at the moment it contains text when i open the form...

thanks for your help.

adz2013
02-06-2002, 12:47 PM
If you can have it enter the default value after update of the previous field. That is the only way that I know.

To do that type
me.field.value=your default value

[This message has been edited by adz2013 (edited 02-06-2002).]

Pat Hartman
02-06-2002, 05:25 PM
Although this method will work it is a little dangerous since if the user for some reason does not update the first field, no value will be placed in the second field. You can put the code in the BeforeUpdate event of the form. In this case you would need to check to see if the user already entered a value so you would not overlay it arbitrarily with the default.