|FDM - fExecuteCustomScriptAsync doens't work [message #538677]
||Sun, 08 January 2012 17:54
Registered: January 2012
Hello community! |
I am novice in FDM, and i would be very greatful, if someone can assist me with my problem in FDM scripting.
FDM version is 188.8.131.52.00
I wrote 2 custom scripts - General and Web scripts
1) General script execute SQL-query that gets data from database.
2) Then data is saved to an Array.
3) Then script open existing XLS file, that is used as a document template (it has columns headers for date, business unit, data and so on).
4) Data is loaded to XLS file.
5) XLS file is SAVED AS in catalog "Archive" with the name "BU_<date>"
WebScript - just execute genereal script with this code:
'Asynchronous Script Processing
'Declare Local Variables
strScriptToRun = "SAP_2_HYP_COPY_XLS" 'Name of the script to execute (Type Custom General Only)
strLoadBalanceServerName = "HYP-APP1T" 'Load balance server for Asynchronous process to use
If API.DataWindow.Utilities.fExecuteCustomScriptAsync(CStr(strScriptToRun), CStr(strLoadBalanceServerName)) = True Then
General script work just fine - all data is loaded from DB to array and then to file, and file with data is saved in "Archive" folder.
The problem is with web script - there is no errors, but it refuses to execute general script ("Failed" MsgBox appears).