Results 1 to 2 of 2

Application.OnTime Code is not working

Threaded View

  1. #1
    Registered User
    Join Date
    03-09-2012
    Location
    ping essdage
    MS-Off Ver
    Excel 2007
    Posts
    1

    Question Application.OnTime Code is not working

    The following code below is not working. The purpose is to execute a macro called InterdayR at 13:45:00 every day. The InterdayR code is also included. I do not understand as to why it is not working. Help! The Excel program remains open throughout the day.

    Sub Interday()
    '
    ' Interday Macro
    '
    Application.OnTime Date + 1 + TimeValue("13:45:00"), "InterdayR"
    '
    End Sub
    
    
    InterdayR
    Sub InterdayR()
    '
    ' InterdayReminder Macro
    '
    'Place your text here
        MyNote = "Has the Interday Located on R8 been populated as of yet???"
    
        'Display MessageBox
        Answer = MsgBox(MyNote, vbQuestion + vbYesNo, "ATTENTION")
    
        If Answer = vbNo Then
            'Code for No button Press
            MsgBox "Please Update the Interday Field!"
        End
        Else
            'Code for Yes button Press
            MsgBox "Thank You!"
        End If
    '
    End Sub
    Last edited by davesexcel; 04-12-2013 at 10:59 PM.

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