Home Forums Microsoft Access Microsoft Access Update Field to current logged in user ID with new record command button RE: Update Field to current logged in user ID with new record command button

  • It is in the right place.

    I'm not sure why you have an On Error Resume Next.

    Set a breakpoint in the code on the Me.txtUserID = Environ("USERNAME") by clicking on that line and pressing F9.

    Then open your form and click the New button.

    If the code execution does not stop on the breakpoint then that would explain why the control is not updating.

    If code execution stops on the breakpoint, press F8 to execute that line and then hover over the "Me.txtUserID" and see what value it has.