I have a script that sends a confirmation text to a cell phone via a URL from Message Bird. It works perfect in PRO but doesn't work if I use perform script on server. The script has no server incompatibility issues... Any ideas?
From where does the script get the URL, message text etc.? Keep in mind that your current context is lost when you PSoS.
Open your script in the script in the Script workspace and check to Server compatible steps. If some steps are greyed out, the they are not compatible with the server.
Thanks Planteg .... I checked that and all 4 lines are compatible..
what error does it return?
Could be a port/firewall issue.
The script is just 2 lines really.. insert from URL into a result field. No error seems to be defined, but the result returns blank.
All the information is contained in the URL.
Thank you Eroist.. the URL gets its information from global fields... I think this might be the problem. Would it be the server doesn't see the global fields from the server side?
The script is run by it’s own account, not the user‘s account, thus globals contents are different.
That may be my problem... I'll try a different approach in the morning as its 23.40 here... perhaps I should set the global's into record fields?
The PSoS script step starts a new user session on the FMS. Its as if a new computer had connected to the DB, which runs the OnFirstWindowOpen script. Then this new session runs whichever script is called in the PSoS step.
The PSOS is not an extension of the client running the script.
You must be sure to establish the context and found set within the script and DO NOT rely on anything in the current user's session. This included any variables and changed global Fields.
Also, all script steps must be server compatible. There is no environmental information from the invoking client, for example: global/regular variables, what files are open or any window's found set.
A PSOS is limited in the same way a scheduled script is limited. It cannot access any file not being served on the same FMS where it resides.
Any information needed from the current user’s session must be passed into the PSoS as Parameters within the Perform script step. For example: layout name, find criteria to get the correct record(s), and data not available in the current file. Or they must be defined within the PSoS script.
Thank you Chocohalic for taking the time to write this explanation, I really appreciate it..... I get it now.. It makes perfect sense..!! I valuable lesson learned..
Thank you everybody for your valuable input... I really appreciate all the helpful comments and explanations..
Retrieving data ...