January 25, 201114 yr Hello Forum, I have an FM 9 Server with 8,5 Clients. (No "you should upgrade" messages please thank you) I want to check in a directory in Windows if a file (whos name I know exactly) exists. Can I do that? Do I absolutely need a file plugin for this? In the end I want the server to execute this script. If it can be done without a plugin please how, if it can only be done with a plugin, how do I do that server-side? Thanks in advance
February 1, 201114 yr Author Hey forum, there were no takers for this question and I did some In depth research. There actually IS a way to do this! You use the Import Script step to find out if a file exists. If the import script step leaves no error, it exists, if it causes an error, it does not exist. Heres 3 Images of what it should look like exactly. Note also the way the import is done into the temporary table which has only 6 number fields, is to ensure that table does not get filled with loads of rubbish just because an import happenned to work. Works like a charm for me. No guarantees are taken for this code, use at your own risk. Best Wishes, Spongebob
February 1, 201114 yr Getting this to run on the server will be the challenge. The server side scripts can only see into very specific folders on the server: the Documents folder inside the Data folder, and the temporary folder. There may be another folder but I cannot recall it just now. You may need a robot machine running FMP to make this happen.
Create an account or sign in to comment