Storing Current Date Information In An Access Data

Results 1 to 2 of 2

Thread: Storing Current Date Information In An Access Data

  1. #1
    Hunter Powers Guest

    Default Storing Current Date Information In An Access Data

    I have a simple login in system. There is a database with a table with three fields, user, password, lastlogin. My problem is with that last login field. I can&#039t figure out how to update last login to the current date. I have included my current code, which doesn&#039t work below.<BR><BR> Dim newdate<BR> newdate = Date()<BR> <BR> objConn.Execute "UPDATE customer SET lastlogin = newdate " & _<BR> "WHERE contact = " & iPollOptionID

  2. #2
    Stephan Zutterman Guest

    Default RE: Storing Current Date Information In An Access

    You need to leave the newdate variable out of the string expression.<BR><BR>It should be:<BR><BR>&#060;%<BR>Dim newdate<BR>newdate = Date()<BR><BR>objConn.Execute "UPDATE customer SET lastlogin = " & newdate & _<BR>"WHERE contact = " & iPollOptionID <BR>%&#062;<BR><BR>Greetings,<BR><BR>Stephan Zutterman<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •