+ Reply to Thread
Results 1 to 4 of 4

Date-based VBA macro selects wrong cell.

  1. #1
    Registered User
    Join Date
    03-07-2013
    Location
    Phoenix, AZ
    MS-Off Ver
    Excel 2007/2010, Outlook 2007/2010
    Posts
    60

    Date-based VBA macro selects wrong cell.

    I have a VBA macro in place which should go line by line and check one date against another to check for overdue information. If the first date is more than 30 prior to today's date a message box should say "Overdue" and if it is within 30 days it should say "Okay." However, when it goes through the macro it puts "Okay" on the line below the line where it should appear. The macro is triggered by a button.

    I realize the code below has additional variables which are not used, but they are necessary for the remainder of the project.

    Please Login or Register  to view this content.
    Last edited by Leith Ross; 03-07-2013 at 07:20 PM. Reason: Added Code Tags

  2. #2
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,482

    Re: Date-based VBA macro selects wrong cell.

    Attach a sample workbook. Make sure there is just enough data to make it clear what is needed. Include BEFORE/AFTER sheets if needed to show the process you're trying to complete or automate. Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic

  3. #3
    Registered User
    Join Date
    03-07-2013
    Location
    Phoenix, AZ
    MS-Off Ver
    Excel 2007/2010, Outlook 2007/2010
    Posts
    60

    Re: Date-based VBA macro selects wrong cell.

    Here you go.

    Tracking.xlsm

  4. #4
    Registered User
    Join Date
    03-07-2013
    Location
    Phoenix, AZ
    MS-Off Ver
    Excel 2007/2010, Outlook 2007/2010
    Posts
    60

    Re: Date-based VBA macro selects wrong cell.

    Bump. I really need an answer here.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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