Siebel SmartScript Administration Guide > Verifying, Testing, and Invoking SmartScripts > Invoking Scripts Through Siebel VB or Siebel eScript >

Invoking a SmartScript from a Currently Running SmartScript


A SmartScript can be invoked from another SmartScript using Siebel VB or Siebel eScript. The currently running SmartScript should be canceled or finished and then the RunSmartScript invoke method can be used to start a new SmartScript.

Usage

You could create a SmartScript that has one SmartScript question start another SmartScript in the current language.

Example
Function Question_PreLeave () As Integer

Function Question_PreLeave () As Integer

CurLang = GetCurrentValue

Script.Finish

If CurLang = "English" THEN

TheApplication.InvokeMethod "RunSmartScript","HSN-New Customer",,"ENU",

"USD"

else

TheApplication.InvokeMethod "RunSmartScript","HSN-New Customer",,"ESP",

"USD"

END IF

Question_PreLeave = ContinueOperation

End Function

Siebel SmartScript Administration Guide