Guest ThaoHuynh Report post Posted 11/10/2017 04:18 AM Hi VoiceGuide Team, I would like to get some parameters to use in scripts, so can i create a config file ( content parameters ...) in another direction and read it to get these parameters in VoiceGuide scripts? Thank you for your support. Share this post Link to post
SupportTeam Report post Posted 11/10/2017 04:50 AM You can create a file that contains data in "Result Variable Definition" format and read that in during the script. eg. if a file localinfo.txt contains this text: [branchname]{seaside}[waittime]{20}[supervisortel]{5551234} then you can read it into VoiceGuide using a Run VBScript module and this code: set fso = CreateObject("Scripting.FileSystemObject")set fileLocalData = fso.OpenTextFile("C:\localinfo.txt")sEntireFile = fileLocalData.ReadAllset fileLocalData = Nothingset fso = Nothingset vg = CreateObject("vgServices.CommandLink")vg.Run_ResultReturn $RV_LINEID, sEntireFileset vg = Nothing and you will then be able to use the following $RVs in your script: $RV[branchname] $RV[waittime] $RV[supervisortel] which will have values of: seaside, 20 and 5551234 respectively. more information on above method: http://www.voiceguide.com/vghelp/source/html/com_run_resultreturn.htm http://www.voiceguide.com/vghelp/source/html/modvbs.htm $RV variables can also be set in VG.IN, in section [scripts], by setting entry GlobalRV eg: GlobalRV=[branchname]{seaside}[waittime]{20}[supervisortel]{5551234} You can also use a Database Query module to retrieve specific data from databases or Excel files etc. http://www.voiceguide.com/vghelp/source/html/moddbquery.htm Share this post Link to post
Guest ThaoHuynh Report post Posted 11/10/2017 10:53 AM Yeah, it's worked for me. Thank you so so much Share this post Link to post