FOLDMONKEY FAQ
Copyright MonkeyJob Systems 2005
All rights reserved

Home FAQ Forums Contact
Download FoldMonkey FAQ Awards Report Bugs
 Search For Data
   

How can I send files to DOS for further automated processing?


Use the following instructions to send file names to DOS:

1.

Right click on the FoldMonkey icon and select "Run as administrator". Find and check the "Launch Program" check box in the "Settings" window.

2.

Check the "Wait For Program To Close Before Moving To Next File" check box.

3.

Enter the following information in the "Launch" section:

Program: C:\mybatchfile.bat
Parameters: "<filePath>" "<newFileName>"

Note: Include the quote marks when entering the above information.

The Launch section should now look like this:

semd name path


4.

Create a batch file C:\mybatchfile.bat with the following contents:

@echo off
cls



rem This block of code will set the variables mypath and myfile:
set mypath=%1
set myfile=%2



rem This block will strip the double quote marks from the variables:
set mypath=%mypath:"=%
set myfile=%myfile:"=%



rem This block will display to the screen the fully qualified file name:
echo.
echo %mypath%\%myfile%



rem This block will delete the file (note that quote marks are required):
del "%mypath%\%myfile%"



echo.
pause
cls
exit

When you start scanning, FoldMonkey will call the batch file for each new file found. The batch file above is designed for demonstration purposes, to output the file name to the DOS screen and then delete that file. Feel free to copy, paste and edit the code to suit your requirements.

You can edit the batch file to suit your needs. For example, you can use the copy or move commands to copy or move the file. You can call third party programs to work on each file etc.

You can access the file path using the %1 variable in the batch file. You can access the file name using the %2 variable in the batch file.



Related Topics:
Frequently Asked Questions
How can I copy AND move files?

  | About Us | Privacy Policy | Terms Of Use | Affiliates | Forums | Copyright ©2003 MonkeyJob Systems All Rights Reserved |