VBA Date Check

  • Hello,


    I am new to using VBA but have some coding in my background.


    I am trying to use this code below so that as I change a cell the date changes to the current change and this works well.



    End Sub



    However, I don't want this date entry to populate when I create new entries. What is the best was to modify this code to do that? Here is some background on the issue:
    In Column A it has the date the entry was added. This has 2 different entries: The actual date it was entered, and "Original" if it was there prior. Is there a way to only run this if the value in the corresponding row in Column A is < Current date or original?


    I tried to play around with this but since it's running as a range I don't have the background to understand the proper way to fix this.


    Any help would be much appreciated! Thank you!

  • Hello and Welcome to the Forum


    Not totally sure to understand your objective ...


    May be following macro can help


    If you feel like saying "Thank You" for the help received, do not hesitate to click the "Like" icon ...just below...in the bottom right corner...:)

  • Hello and Thank You!


    This works great for all the dates that are less than the current date. Thank You!


    However, there is one more objective.
    - In many rows in column A (the date entered column), the column A entry is "Original". This is referencing data that was never added and has existed since the file was made.


    Is there any way for rows with the entry "Original" in column A to also be affected and update with the current date if altered.


    Thank you again for your help!

  • Code Tags Added
    Your post does not comply with our Forum RULES. Use code tags around code.


    Posting code between

    Code

    tags makes your code much easier to read and copy for testing, it also maintains VBA formatting.


    Highlight your code and click the # icon at the top of your post window.


    (I have added them for you today. Please take a few minutes to read all Forum Rules and comply in the future.)

  • Glad it is helping you out ...


    Below is the latest modification



    Hope this will help

    If you feel like saying "Thank You" for the help received, do not hesitate to click the "Like" icon ...just below...in the bottom right corner...:)