January 21, 201213 yr I wrote a script which is coping files onto a USB key using information from the filemaker pro database. However, when the script executes, I can no longer have access to other function in the dbms. Is there a way to run a script in the background (like a batch job) and not have to wait for the script to finish. Thanks! Daniel.
January 21, 201213 yr Automatic message This topic has been moved from "FileMaker Product Family → FileMaker Pro 10" to "Database Schema & Business Logic → Managing Scripts".
January 21, 201213 yr Short answer - no, client scripts run in the foreground. Can you move this to a server script? If you expand on the purpose, we may be able to offer other approaches.
January 21, 201213 yr Author I wrote an AppleScript which copies files onto USB keys. I could be serving more than three clients simultaniously. Customer #1 comes and ask for file A+B; Costumer #2 comes and ask for file C+D+E; Costumer #3 comes and ask for file F+G+H; Costumer #4 comes and ask for file I+J+K; Each files are between 400 and 600 mb. I do have a USB 3.0 hub which allow me to connect up to 5 USB 3.0 keys simultaneously. At the same time files are being copied, customer order still have to be registered to the database. At this moment the system via a script can only copy one key at a time and during the time the scrip execute I cannot enter new customer orders. I would like to be to able to have simultaneous copy to start at the same time and still be able to perform new customer orders. Would FileMaker Server allow me to perform such a thing? Thanks for your help !
January 22, 201213 yr The trick here, I think, is to have another application run the AppleScript. I'd try saving it as an application and using Filemaker's AppleScript merely to trigger it. [untested]
January 22, 201213 yr Author Thanks Comment for the answer. If I understand correctly your information, you : would use FMP applescript to create an application ; use FMP applescript to to trigger/start that application. On a MAC what type of application would you suggest I should create? On a PC I would probably write a .bat file.
January 22, 201213 yr Slightly off topic but I had a parallel situation when sending large amounts of big emails to a remote smtp server from a Filemaker client, it was taking 6 to 8 hours during which Filemaker was 'locked'. My best solution so far was to set up a local mail server and relay through that, it now takes about 10 mins to free Filemaker and the mailserver takes the load, I guess this could be further improved by raising LAN speed. I have not tested this using FMServer but I suspect that a full on smtp 'flow' would bring it to a crawl but would like to hear if anyone has experience with this. Just my 2 pence worth.
January 23, 201213 yr Author As suggested, I've used AppleScript Editor to save the script as application I then executed the script using the following statement set theScript to (path to home folder as text) & "_CopytoUSB.scpt" run script file theScript Unfortunately same problem. I cannot used the DBMS while the script is running. Some people says I should use FileMaker Server, would this solved my problem ? Would there be a way to test that it work before acquiring FileMaker Server ? Regards! Daniel
January 23, 201213 yr Author I've used something like this tell me activate set s to display dialog "Which appliation do you want to start?" default answer "Safari" do shell script "open -a "" & text returned of s & """ end tell and it is now working, FileMaker Pro is accessible while it is copying. Thanks
Create an account or sign in to comment