Cannot run batch files

Posted on 2009-04-30
Last Modified: 2012-05-06
Im having a problem with three machines (I suspect since the latest Micrososft patches last week).  The issue is the machines will not run any batch files as a specific user from the Windows XP Gui.  If you go to a cmd prompt you can run them fine, if you schedule them with the users credentials it works fine.

The exact error is "Windows cannot find 'c:\test.bat'. Make sure you typed the name correctly, and then try again.  To search for a file, click the start button, and then click Seach".

It doesnt matter where the batch file is.  If you right click on the batch file and choose edit you can view it, make amendments, save it, which suggests theres no permissions issue?

I've tried running the various registry scripts to reassociate batch files correctly, but they dont have any effect.
Question by:pmason08
    LVL 16

    Expert Comment

    Tried renaming them as .CMD files?

    Author Comment

    Yep, same thing.
    LVL 15

    Expert Comment

    The error is stating that it cannot find the file, how are you running the scripts? If you are doing this via a link then try re-creating the link.

    Author Comment

    No I was running them via double clicking the source file, not a shortcut.

    Author Comment

    Right I've fixed this, and I cant really explain why.

    I noticed on all the users who had the issue, one of their network drives wasnt mapping correctly, it appeared to be mapped in explorer, but if you double clicked on it you just got a empty folder.

    Upon further investigation the users home drive permissions were incorrect (most puzzling as they had worked ok previously).  When I fixed this, rebooted the machines and the folder mapped ok, the batch files worked again.

    If the batch files in question had been using this volume, or any network volume it might make more sense to me, but they were local scripts that did nothing via the network.

    Still hopefully this might help if anyone else see's this issue.

    Thanks for responses.
    LVL 15

    Accepted Solution

    I posted:

    The error is stating that it cannot find the file

    the author posted:

    one of their network drives wasnt mapping correctly,

    If the mapping was not there the file would not be run from a cmd prompt!

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    IT, Stop Being Called Into Every Meeting

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    cPanel is a Unix based web hosting control panel that provides a graphical interface and automation tools designed to simplify the process of hosting a web site. cPanel utilizes a 3 tier structure that provides functionality for administrators, rese…
    Step by step guide to Clean and Sort your windows registry! Introduction: Always remember: A Clean registry = Better performance = Save your invaluable time In this article we're going to clear our registry manually! Yes, manually! The e…
    This video discusses moving either the default database or any database to a new volume.
    This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor ( If you're looking for how to monitor bandwidth using netflow or packet s…

    758 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    7 Experts available now in Live!

    Get 1:1 Help Now