Jump to content

This topic is 4777 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

I am sure i am just doing it wrong. My script has two output variables, result and resultCode.

I am calling my script as an external function.

When I attempt to access these variables I get this error:

12/27/11 1:45:36 PM [0x0-0x671671].com.filemaker.client.pro[21838] SEVERE: PluginFunction PluginFunction{name='SMGetVariable', functionID=-28360, minArgs=null, maxArgs=1} got an error with converted args [resultCode]

12/27/11 1:45:36 PM [0x0-0x671671].com.filemaker.client.pro[21838] java.lang.IllegalStateException: You can only get ScriptMaster variables after evaluating a script, and before setting any new variables.




The FMP scripting looks like this:




Set Variable [ $customerResult;Value:CreateAuthorizeNetClient( $customer ) ]

Set Variable [ $result , SMGetVariable( "result") ]

I am not explicitly calling EvaluateGroovy but I assumed that using the Set Variable methodology on my java would still allow me to access the output variables. The script works and in the Scriptmaster tools the output vars are populated as expected.

This is probably embarrassingly simple :) I sure hope so!

Tx

Posted

In the process of trying to put a demo video together it seems to work properly now.. I rebooted the other day so maybe 'something' flushed out.

Anyhow, all seems well now. If this reoccurs I'll ping you via email.

Thanks Brent!

John-

Can you send the FM file you are using to [email protected]?

Posted

Thats exactly it. A workaround is to return an array out of my plugin function. This array is automatically transformed into a delimited list which can be dealt with.

Posted

John, I thought we were communicating with you by email. We were able to add the SMGetVariable function to generated plugins. If you need it let me know (email preferably) and it will also be added to the next release of ScriptMaster.

Posted

Absolutely, i was replying but trying not to let the cat out of the bag until you released it :)

Yes, it works now and yes it is FULL OF AWESOME.

Thanks guys

John-

John, I thought we were communicating with you by email. We were able to add the SMGetVariable function to generated plugins. If you need it let me know (email preferably) and it will also be added to the next release of ScriptMaster.

Posted

Ok. Thanks for being discreet John. I'll follow suit and "not let the cat out the bag" myself but suffice it to say we are about to release a new version of ScriptMaster. It will include not only this feature but also something forum posters have been requesting for a while. Stay tuned...

This topic is 4777 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.