textbox to table problem

  • Thread starter Thread starter John Daily
  • Start date Start date
J

John Daily

I have two text boxes on a startup form that have default
values in them. One is the users name and the other is
the current date/time. The user is not able to change the
fields. I have the form bound to the table I want to hold
the data, LoginInfo.
My problem is that I can't get the data to populate the
table when the user starts access.

Please help!

TIA,

John
 
John Daily said:
I have two text boxes on a startup form that have default
values in them. One is the users name and the other is
the current date/time. The user is not able to change the
fields. I have the form bound to the table I want to hold
the data, LoginInfo.
My problem is that I can't get the data to populate the
table when the user starts access.

Default values alone will not create a record. Either the user or your
code must "dirty" the record by explicitly setting a value. If you remove
the default of Now() for your DateTime field and instead have code that
sets the control to Now() in an appropriate event, then a record will be
created. You might want that same code to issue a save (Me.Dirty=False) as
well.
 
Back
Top