+ Reply to Thread
Results 1 to 5 of 5

macro pauses

  1. #1
    Gerry
    Guest

    macro pauses

    I have been running a macro for a few weeks. All of a sudden it began
    stopping on one line, with no error message. I hit the play button and
    the macro continues to the end.

    Any ideas?

    TIA
    Gerry


  2. #2
    Gary L Brown
    Guest

    RE: macro pauses

    Tell us what the line is, Gerry.
    --
    Gary Brown


    "Gerry" wrote:

    > I have been running a macro for a few weeks. All of a sudden it began
    > stopping on one line, with no error message. I hit the play button and
    > the macro continues to the end.
    >
    > Any ideas?
    >
    > TIA
    > Gerry
    >
    >


  3. #3
    Gerry Waldram
    Guest

    RE: macro pauses

    Here is the line it is pausing on.

    ActiveWorkbook.SaveAs Filename:="C:\Shared
    Data\RetailPro\Retail\Rpro\PRINT\Inventory for G Site
    old.txt",FileFormat:=xlText, CreateBackup:=False

    Gerry


    *** Sent via Developersdex http://www.developersdex.com ***

  4. #4
    Gary L Brown
    Guest

    RE: macro pauses

    My best guess is that in the past, after creating the file "Inventory for G
    Site old.txt", it has been moved, deleted and/or name changed.

    Try putting the following lines in front of the line that is pausing...

    Application.DisplayAlerts = False 'turn warnings off
    Kill :="C:\Shared Data\RetailPro\Retail\Rpro\PRINT\Inventory for G Site
    old.txt"
    Application.DisplayAlerts = True 'turn warnings on

    This will delete the old file without stopping the code/displaying warnings
    just before you are creating the file with your line...

    > ActiveWorkbook.SaveAs Filename:="C:\Shared
    > Data\RetailPro\Retail\Rpro\PRINT\Inventory for G Site
    > old.txt",FileFormat:=xlText, CreateBackup:=False


    HTH,
    --
    Gary Brown
    gary_brown@ge_NOSPAM.com
    If this post was helpful, please click the ''''Yes'''' button next to
    ''''Was this Post Helpfull to you?".


    "Gerry Waldram" wrote:

    > Here is the line it is pausing on.
    >
    > ActiveWorkbook.SaveAs Filename:="C:\Shared
    > Data\RetailPro\Retail\Rpro\PRINT\Inventory for G Site
    > old.txt",FileFormat:=xlText, CreateBackup:=False
    >
    > Gerry
    >
    >
    > *** Sent via Developersdex http://www.developersdex.com ***
    >


  5. #5
    Gerry
    Guest

    Re: macro pauses

    Thanks Gary


+ 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