fExecuteCustomScriptAsync doens't work
907664Dec 28 2011 — edited Jul 31 2012Hello community!
I am novice in FDM, and i would be very greatful, if you assist me with my problem in FDM scripting.
FDM version is 11.1.2.1.00
I wrote 2 custom scripts - General and Web scripts
General script:
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:
Sub webwebSAP2FDM()
'Asynchronous Script Processing
'Declare Local Variables
Dim strScriptToRun
Dim strLoadBalanceServerName
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
MsgBox "OK"
Else
MsgBox "Failed"
End If
End Sub
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).
Best regards,
Mike
Edited by: 904661 on 27.12.2011 23:58