stuj1026 Posted December 30, 2003 Posted December 30, 2003 Here is a tough one! I would like to run a script based on the value of a field ie: Fieldx = happy Instead of using if statement in my script such as if fieldx=happy perform script happy end if if fieldx=sad perform script sad end if i would prefer to bypass the if statement and perform script (value)fieldx is this possible? Stu
-Queue- Posted December 30, 2003 Posted December 30, 2003 Wouldn't that be nice? Unfortunately, scripts must be explicitly called.
CobaltSky Posted December 31, 2003 Posted December 31, 2003 Sad, but true - present versions of FileMaker don't provide a way to use field values to directly determine which script is to be run, but require you to do the hard slog of building up your own selection procedure using a nest of If[ ] steps. But as Queue has observed, the feature you're looking for would be nice - so I'd encourage you not to let it rest there, but to pay a visit to the FMI feature request page and suggest that it be included in a future version. The URL for requests of this kind is: http://www.filemaker.com/company/product_feature_request.html I've already done so myself, but if enough folks make the suggestion, you just might see it in a future version.
bruceR Posted December 31, 2003 Posted December 31, 2003 I would like to run a script based on the value of a field ie: Fieldx = happy is this possible? No prob with applescript. copy cell "WhichScript" of current record to whichScript do script FileMaker script whichscript It's also possible using the shell script plugin to do this automatically just entering a value in a field.
stuj1026 Posted December 31, 2003 Author Posted December 31, 2003 Im running in a windows enviroment.. Is there a shell script plugin for windows?
Charles Delfs Posted January 1, 2004 Posted January 1, 2004 I have writen a vb add-on program called Dynascript that can do this, as it was a nesesity for a project. Email me if you are interested. Charles
stuj1026 Posted January 2, 2004 Author Posted January 2, 2004 If anyone is interested I figured it out using the Troi Activator Plugin.. Following is the two line script External("Actr-StartListener", "54242" & "|" & Status( CurrentFileName) & "|xxxxxx") External("Actr-SendRemoteEvent","54242" & "|" &External("Actr-GetIPAddress", "")& "|" &"xxxxxx" & "|" &Status( CurrentFileName) & "|" & act_Script_to_run & "|" & "" & "|" & "") Thanks for the feedback Stu
Recommended Posts
This topic is 7634 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now