December 12, 201015 yr Hi when using the perform script step within an existing script, is it possible to select the new script to perform dynamically via a variable? My thinking is as follows:- My initial script sets variables and calls various dialog boxes:- I then plan to have various different scripts set up for the various reports I need to export so if $$Variable=1 then perform script1 $$Variable=2 then perform script2 Regards Dave
December 12, 201015 yr Sure. It would be a series of: If [ $$variable = 1 ] Perform Script [ some script ] Else If [ $$variable = 2 ] Perform Script [ some other script ] Else Beep Show Custom Dialog [ "Script name error" ] End If I highly recommend an Else to tell you if your variable tests match no scripts. There is no way (yet) in native FileMaker to "perform script by name" (though, oddly enough, external tools like AppleScript, or any other tool which can call a FileMaker script, all call FileMaker scripts by name; so that is another option; though then totally dependent on knowing the name).
Create an account or sign in to comment