Paths

Paths is the name given to the transitions between the Script Modules.

Creating new paths

To create a new path, press the Properties button on the module from which the path will start, and go to the Paths tab.

Paths are specified using the format:

On {Trigger} Goto [Module Title]

The text in the Paths window can be edited directly, or you can use the Add New Path help frame.

 

Selection Paths

Taken when caller has made a matching selection. This can be a keypress or a series of keypresses, a keyword or phrase recognised by the Speech Recogntion system, matching data retrieved from databse or web service, or data returned by external program or VBScript/JavaScript etc.

 

Timeout Paths

A Timeout path will be taken if a caller has not made a selection within the specified number of seconds. A Timeout path with a wait time of zero seconds will be taken immediately after the last sound file in the module has completed playing.

 

Paths to Voicemail System

Paths can direct the caller to a Voicemail Box, Voicemail Box Menu or Voicemail Retrieve Menu, eg:

When specifying the Voicemail Box as the destination, the Voicemail Box number must be specified as well. make sure that the Voicemail Box specified exists and has been configured using the Voicemail System Manager.

 

Returning from the Voicemail system

If you would like the caller to go to a certain module after returning from the Voicemail system then you can specify a return module. The Path definition needs to be:

On {Trigger} Goto [Voicemail System Module] Return [Module Title]

Eg: if after Retrieving Voicemail the caller should be sent to the main menu again, the path will look like this:

If the titles of the modules are too long to fit on one line, the path description will wrap around to the following lines. This is OK.

 

Branching to other scripts and calling subscrips.

The Enterprise and Evaluation versions of VoiceGuide can call subscripts.

To branch (goto) to a script you can specify a path like this:

on {event} goto [script filename|module name]

eg:

on {1} goto [c:\scripts\myscript.vgs|PlayWelcome]

To run a subscript (gosub) to a script you can specify a path:

on {event} gosub [script filename|module name]

eg:

on {1} gosub [c:\scripts\myscript.vgs|PlayWelcome]

The script name or the module name can be left blank. If the Script Filename is left blank then the current script is assumed, and if the Module Name is left blank then the default starting module in the script is used.

eg: on {1} gosub [|PlayWelcome]

on {1} gosub [c:\scripts\myscript.vgs|]

If the [|module name] notation is used the path to the destination module will not be drawn. This notation can be used to visually de-clutter highly linked scripts.

If "|" is omitted from the destination specification then the destination name is assumed to be just a module in the current script. So for example this path will not work:

on {1} gosub [c:\scripts\myscript.vgs] 

 

To specify what module should be the next module once the subscript returns the "return" path option should be used. If the "return" path option is not used when the subscript returns then VoiceGuide will start running the default start module in the returned to script.

To specify a return module:

on {event} gosub [script filename|module name] return [return script filename|return module name]

eg:

on {1} gosub [c:\scripts\admin.vgs|GetUserPin] return [c:\TakeOrder.vgs|MainMenu]

The Return To script can be a different script. The return script filename can be omitted if you would like the subscript to return to the same script.

To return from a subscript use a path like this in the subscript:

on {event} return

eg: on {4} return

The various goto/gosub/return paths are briefly demonstrated in the sample scripts in VoiceGuide's \scripts\more sample scripts\paths directory.

 

Subscripts using COM/WCF interface.

Please see the VoiceGuide COM/WCF Reference section in this Help file for information on how the goto/gosub/return commands can be issued to VoiceGuide from external applications.