+ Reply to Thread
Results 1 to 5 of 5

Inserting Current Date in First Cell of New Row in Table

  1. #1
    Registered User
    Join Date
    04-15-2018
    Location
    Mexicali, Baja California, Mexico
    MS-Off Ver
    2010 & 2016
    Posts
    18

    Question Inserting Current Date in First Cell of New Row in Table

    I have three tables that track incoming messages. When someone begins filling out a new row they have to enter the current date in the first cell first then go about filling out other cells.
    Most of the time they save themselves time by dragging down the current date about as many rows as they thing they'll need except that sometimes they're over and somethimes they're under.
    I want the first cell (column A) to auto populate with the current date as soon as the next line in the table is created.

    I have a standard Excel Table that autofills in certain cells with formulas, and I would like for the first cell in each row to auto fill with the current date without leaving it as a formula that would change the next day.

    Any help would be appreciated.
    Last edited by DavidFC; 02-11-2019 at 11:27 AM.

  2. #2
    Banned User!
    Join Date
    01-26-2019
    Location
    United States
    MS-Off Ver
    2010
    Posts
    32

    Re: Inserting Current Date in First Cell of New Row in Table

    Maybe like this:

    =IF(B2<>"", IF(A2="",NOW(),A2), "")

  3. #3
    Registered User
    Join Date
    04-15-2018
    Location
    Mexicali, Baja California, Mexico
    MS-Off Ver
    2010 & 2016
    Posts
    18

    Re: Inserting Current Date in First Cell of New Row in Table

    The downside with this function is that the Now() date/time would change with, well, time.

    What I need is a macro that will automatically enter the current date as a value as soon as a new row is added to the Excel Table.

  4. #4
    Banned User!
    Join Date
    01-26-2019
    Location
    United States
    MS-Off Ver
    2010
    Posts
    32

    Re: Inserting Current Date in First Cell of New Row in Table

    With the macro in place, anytime you enter something into a cell in column A, the adjacent cell in column B will contain the date and time (formatted to show only the time). If you delete something in column A, then the adjacent cell in column B is cleared, as well.

    Note, as well, that you can change the setting for the NumberFormat property to reflect how you want the date to appear. As an example, you could change to a twelve-hour time format by changing "hh:mm:ss" to "h:mm:ss AM/PM".

    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    04-15-2018
    Location
    Mexicali, Baja California, Mexico
    MS-Off Ver
    2010 & 2016
    Posts
    18

    Re: Inserting Current Date in First Cell of New Row in Table

    Thanks so much this worked very well.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Inserting new row in table will auto populate and save current _date
    By antexity in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-30-2015, 01:01 PM
  2. If cell value's change , inserting current date
    By otacon23 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 12-09-2013, 09:52 AM
  3. [SOLVED] copy and paste in current active cell, and need current date then scroll down 140 lines
    By vengatvj in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-04-2013, 03:40 AM
  4. VBA Code for inserting snap shot of current date and time into text box
    By jamer02 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-16-2010, 07:19 AM
  5. Replies: 6
    Last Post: 08-29-2010, 08:15 AM
  6. Deleting rows older than current date and inserting a new row
    By Dan E. in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 12-14-2005, 11:20 AM
  7. [SOLVED] Excel 2003 Inserting current date
    By mark in forum Excel General
    Replies: 3
    Last Post: 02-09-2005, 02:06 PM

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1