Search found 42 matches
- 17 Mar 2016 21:40
- Forum: DOS Batch Forum
- Topic: Calling devcon from a batch
- Replies: 9
- Views: 9926
Re: Calling devcon from a batch
Are there any error messages when it is directly launched? Place a pause as the final line to see them before it exits. It is also specifically looking for devcon in the same folder that the batch is in, rather than c:\windows\system32, but that should be the same no matter how you launch it.
- 04 Mar 2016 16:09
- Forum: DOS Batch Forum
- Topic: Batch Script Errors Works on my laptop but not others
- Replies: 6
- Views: 5764
Re: Batch Script Errors Works on my laptop but not others
Is the error message still the same? What line is causing it? Please provide as much detail as possible. Due to it relying on the vbs file and printers, other people can't test the script themselves.
I also see that if someone enters an option other than 1-4, it's going to fall through to option 1.
I also see that if someone enters an option other than 1-4, it's going to fall through to option 1.
- 04 Mar 2016 15:25
- Forum: DOS Batch Forum
- Topic: Batch Script Errors Works on my laptop but not others
- Replies: 6
- Views: 5764
Re: Batch Script Errors Works on my laptop but not others
cscript %WINDIR%\F:\Prnport.vbs -a -r IP_192.***.***.*** -h 192.***.***.***.80 -o raw -n 9100 cscript %WINDIR%\System32\Printing_Admin_Scripts\en-US\Prnport.vbs -a -r IP_192.***.***.*** -h 192.***.***.*** -o cscript %WINDIR%\System32\Printing_Admin_Scripts\en-US\Prnport.vbs -a -r IP_192.***.***.***...
- 04 Mar 2016 08:48
- Forum: DOS Batch Forum
- Topic: Script to monitor folder size
- Replies: 4
- Views: 4449
Re: Script to monitor folder size
Good to know, I never tested them extensively.foxidrive wrote:Many commands do support that syntax, try the copy or xcopy commands.
- 03 Mar 2016 08:55
- Forum: DOS Batch Forum
- Topic: Script to monitor folder size
- Replies: 4
- Views: 4449
Re: Script to monitor folder size
Please provide as many details as possible about the task. What do you have so far, and what errors are you encountering? Does the folder you are monitoring contain subfolders that need to be accounted for? Hidden files? in a remote pc like: \\pc2\folder1 As far as I am aware, network paths like tha...
- 17 Feb 2016 15:34
- Forum: DOS Batch Forum
- Topic: Catching User Input on "Terminate batch job (Y/N)?" prompt
- Replies: 7
- Views: 7671
Re: Catching User Input on "Terminate batch job (Y/N)?" prompt
So this is not a function that needs to be called from a certain place in a batch? Its actually an example of starting your own batch script, so one needs to substitute %0 with its own batch name, and %* with its batch args - correct? If not, where this snippet must be placed in a batch code? %0 is...
- 17 Feb 2016 09:41
- Forum: DOS Batch Forum
- Topic: Call BAT-File (which uses as properties.csv ) from JAVASCript/HTML
- Replies: 9
- Views: 11617
Re: Call BAT-File (which uses as properties.csv ) from JAVASCript/HTML
All good, except it doesn't work in a standard web browser. Agreed. I tried it in the most current Firefox with no success. The file path isn't correctly escaped, for starters, but even when I fixed that, all it does is display the contents of the batch file in the browser window. Nothing is actual...
- 16 Feb 2016 15:44
- Forum: DOS Batch Forum
- Topic: Catching User Input on "Terminate batch job (Y/N)?" prompt
- Replies: 7
- Views: 7671
Re: Catching User Input on "Terminate batch job (Y/N)?" prompt
The redirection technique you linked doesn't actually ignore Ctrl+C completely. In Win7 at least, the prompt still appears, but is moved past. By rapidly pressing Ctrl+C as fast as I could, I was able to bypass that and get a prompt that allowed me to cancel my script. The code snippet you posted is...
- 16 Feb 2016 15:14
- Forum: DOS Batch Forum
- Topic: Call BAT-File (which uses as properties.csv ) from JAVASCript/HTML
- Replies: 9
- Views: 11617
Re: Call BAT-File (which uses as properties.csv ) from JAVASCript/HTML
I believe an HTML document can execute a batch script through CGI. If that is the case, what's probably happening is that the working directory is the one the HTML server is running from, and not the one the batch file is in. Have your batch file either use the full path to the CSV file, or preferab...
- 25 Jan 2016 16:40
- Forum: DOS Batch Forum
- Topic: Echoing paths to log file shows \\ in path names instead of \
- Replies: 6
- Views: 5310
Re: Echoing paths to log file shows \\ in path names instead of \
As mentioned above, it's definitely coming from the initial command line that the batch is launched from. Most, if not all, file operations don't care if you have extra slashes in the path, which is why the move works. If the extra slashes in the log cause you a problem, you can try expanding the of...
- 21 Jan 2016 10:59
- Forum: DOS Batch Forum
- Topic: Use Relative path in Batch file?
- Replies: 5
- Views: 7824
Re: Use Relative path in Batch file?
Is there anything else in your batch file? Both of the lines you posted give the correct results when I test them myself.
- 20 Jan 2016 16:19
- Forum: DOS Batch Forum
- Topic: Use Relative path in Batch file?
- Replies: 5
- Views: 7824
Re: Use Relative path in Batch file?
For your first part, the closest solution to what you already have would be for /r %%i in (.) do copy "S:\PathnameHere\Atari 7800.psd" "%%i\" for /r already defaults to the current directory if you leave one out, but using it with (.) as you did leaves a trailing '.' at the end o...