+ Reply to Thread
Results 1 to 2 of 2

Run 2nd sub procedure when the first is done successful

  1. #1
    Registered User
    Join Date
    11-05-2009
    Location
    NL
    MS-Off Ver
    Excel 2007
    Posts
    54

    Run 2nd sub procedure when the first is done successful

    Hello,

    With VBA I load a batch script. Then I run a 2nd procedure in VBA. The 2nd procedure should only run if the batch script is closed.

    Please Login or Register  to view this content.
    I found the following somewhere on Google. I do not know if it has to do with what I want.

    Please Login or Register  to view this content.

    Please Login or Register  to view this content.
    I get here a message: Object required


    If anyone can help me I appreciate it.


    Best regards,

    grid

    Last edited by grid; 01-06-2010 at 03:55 PM. Reason: Solved

  2. #2
    Registered User
    Join Date
    11-05-2009
    Location
    NL
    MS-Off Ver
    Excel 2007
    Posts
    54

    Re: Run 2nd sub procedure when the first is done successful

    Hello,

    It has been resolved. I found out how it works. The solution is on this page:

    http://www.scottandmichelle.net/scot...mv?codenum=069

    I've adapted the script of the page. I have adapted these lines:

    ShellAndWait "notepad", vbNormalFocus, True

    To:

    ShellAndWait "C:\temp.bat", vbNormalFocus, True

    This line opens temp.bat (the batch script). Below is the next line. The next line is only executed if temp.bat closed.


    Best regards,

    grid

    Last edited by grid; 01-06-2010 at 03:54 PM.

+ 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