This function calls the macro on the server side with the defined string parameter.
object.CallMacroOnServer(aMacroText[, aTimeOut = 0[,
aInput = ""]])
Part | Attribute | Type | Description |
---|---|---|---|
object |
Required | The object always implements the
ISProfile interface |
|
aMacroText |
In, Required | string |
The text of the server macro |
aTimeOut |
In, Optional Default value is 0 |
int |
The limit for the server macro execution
time |
aInput |
In, Optional Default value is "" |
string |
The string value that will be transferred to the
server macro |
object
Run the macro on the server side and display the computed result.
Dim aMacroText
Dim aTimeOut
Dim aInput
Dim aResult
aMacroText = _
"Dim aMacroReturn, aMacroInput" & vbNewLine &_
"set aMacroReturn = Profile.Variable(""MacroResult"") " & vbNewLine &_
"set aMacroInput = Profile.Variable(""InputParam"") " & vbNewLine &_
"aMacroReturn.Value = ""The Input Value is "" & aMacroInput.Value "
aTimeOut = 10000 'ms
aInput = "123"
aResult = Profile.CallMacroOnServer(aMacroText, aTimeOut, aInput)
Profile.MsgBox(aResult)