Form - Cannot Assign Value
Posted on 2010-09-08
This is weird. I have another db set up to do a similar thing, but cannot replicate it here.
I have a form that has a bunch of buttons on it to run reports. I want to capture when the form was opened, and who opened it. I put two non-visible controls on the form "OpenDate" and "User". I created a table with these two fields. The idea is to log the current date/time, and the userID in those fields when the form is opened. On the Form_Open event, I have:
Me.OpenDate = Now()
Me.User = GetUserCredentials(2)
I get a 'You can't assign a value to this object' error for the first line, and 'Sub or Function not defined' for the second line.