How to integrate batch script with filemaker script through a scheduler in filemaker pro?
.bat files live in the scripts folder on the server:
C:/Program Files/FileMaker/FileMaker Server/Data/Scripts/
then you can select the batch files to run in the server admin console during your schedules.
i have followed the same procedure but it seems there is some error while running the script
What errors are reported?
What does the schedule report?
What is the batch file supposed to do?
2017-08-14 12:00:00.336 -0700 Information 152 EBIOSDSFM14A Schedule "Test" aborted; aborted by user.
the batch file should move the files from one folder to another folder and also which ever files have error it should throw an email notification to the user and lastly it should archive the files to the archive folder.
Ok, depending on how proficient you are with the CMD CLI (you may want to use VBscript if that is a better choice for you): build in some logging so that the script tracks its own progress in a log file and will output any errors there too.
Remember that FMS runs as 'local system' unless you specified otherwise. That usually has no problem with folders on the machine itself but if you are trying to reach folders outside of the machine then that won't work.
The script which we are using is in VB script and we are running the FMS script as 'local system'.
The folders are inside of the machine.
Ok, so make it log every step of the way and do some error trapping/reporting.
I don't see any error while executing the script but when i cross check in folders to check whether it got processed or not.It shows the same place where already files are kept before.
vmazum wrote: It shows the same place where already files are kept before.
It shows the same place where already files are kept before.
I don't know what that means... are you saying that it looks like the script did run or did not run?
The script did not run successfully
And have you added logging logic to the script? If it runs fine when you execute it, that does not mean it will run fine when it is run under the 'local system' umbrella that FMS uses.
what does logging logic to the script means?
It means that you have your VBscript write to a log file before and after each relevant step and whenever it traps an error, then it writes the error details. That way you can always check what it completed and what not, and what errors it ran into.
Yes,that VB script we have converted in batch file and that batch file i have invoke in FM application but when i try to run the script its neither showing any error and also it not processing.
I keep getting confused:
- you don't need to convert a VBscript to a batch file. Both FMP and FMS can execute either one. And IMHO VBscript is easier to code and make it do things like logging.
- you mention "invoke in FM application"... I thought we were talking about FMS schedules?
yes,i want to integrate batch script with filemaker script.But whenever i am running the script its not processing the files from one to another folder.After that FM script should automatically import the data in database but the import its not functioning properly.
Retrieving data ...