?
Solved

Cannot run batch files

Posted on 2009-04-30
6
Medium Priority
?
602 Views
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.
0
Comment
Question by:pmason08
  • 3
  • 2
6 Comments
 
LVL 20

Expert Comment

by:Mal Osborne
ID: 24267962
Tried renaming them as .CMD files?
0
 

Author Comment

by:pmason08
ID: 24267994
Yep, same thing.
0
 
LVL 15

Expert Comment

by:fishadr
ID: 24268068
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.
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 

Author Comment

by:pmason08
ID: 24268123
No I was running them via double clicking the source file, not a shortcut.
0
 

Author Comment

by:pmason08
ID: 24268139
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.
0
 
LVL 15

Accepted Solution

by:
fishadr earned 1500 total points
ID: 24268225
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!
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Disclosure: Use this tutorial only when no other options helps to get Windows XP running without any problems and you don't want to format the drive. The back up of the data is the responsible of the user, however there is a description of how t…
There are 2 things you must have in order to connect to the internet behind a router, The "Gateway IP" of the router, which is usually something like 192.168.xxx.1, I've seen routers with default values of: 192.168.0.1, 192.168.1.1, 192.168.11.1, …
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Suggested Courses
Course of the Month15 days, left to enroll

840 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