[AccessD] Set text box default value to nothing

Charlotte Foust charlotte.foust at gmail.com
Mon Jan 24 12:52:26 CST 2011


Have you tried switching the code to the form Open event?

Charlotte Foust

On Mon, Jan 24, 2011 at 10:45 AM, Susan Harkins <ssharkins at gmail.com> wrote:
> I've tried the following to set a control's (text box) Default Value property setting to nothing, but it's not working:
>
> In the Form_Close event, I've used
>
> txtCreatedBy.DefaultValue = vbNullString
> txtCreatedBy.DefaultValue = ""
>
> Neither works. When I reopen the form, the control is still showing the previously-set Default Value.
>
> I want to wipe out the Default Value setting, close the file, and when reopened, have an empty control, because there is no Default Value setting. Any help?
>
> I'm setting this control's Default Value property using VBA -- the control's AfterUpdate event, so I can't figure out why the form is saving it to begin with. I expected this property to be temporary -- just while the form was open. I didn't anticipate this particular problem.
>
> Susan H.
> --
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
>




More information about the AccessD mailing list