Guest Rhys Daniell Report post Posted 09/23/2005 04:22 AM As you're probably painfully aware by now <g> I'm using VBScript to run a stored procedure and retrieve a result. I'd now like to branch based on a value returned by the stored procedure (there are about 6 values, 1-6). Is there a way of making a value determined in the 'Verify Entered Number' tab available in the 'Paths' tab, and branching based on it? e.g. Case ReturnValue of {1} Goto .... of {2} Goto ... TIA Rhys Share this post Link to post
SupportTeam Report post Posted 09/23/2005 05:04 AM Bit hard to do this in the same module. Best to set an RV which you can then evaluate in a following "Evaluate Expression" module (branched to using a "Success" path). Share this post Link to post
RhysD Report post Posted 09/23/2005 05:34 AM I'd prefer to do it in a different module but the doco says I can't use 'global' variables. Can you suggest an RV I can use to pass data between modules? Share this post Link to post
SupportTeam Report post Posted 09/23/2005 07:07 AM You can either create an RV within the VBScript you run in the 'Verify Entered Number' tab using: http://www.voiceguide.com/vghelp/html/com_RvSet.htm http://www.voiceguide.com/vghelp/html/com_...vSet_RvList.htm or just jump directly to the module/script of choice using http://www.voiceguide.com/vghelp/html/com_...Script_Goto.htm http://www.voiceguide.com/vghelp/html/com_...cript_Gosub.htm the doco says I can't use 'global' variables. ? where does it say that? Can you post the actual quote you are referring to please. Share this post Link to post
RhysD Report post Posted 09/23/2005 07:25 AM It wasn't the doco, I found this when searching your site for "global variables" It seems it is now old news? "Result Variables are local to the channel on which they are defined. Right now there is no mechanism for defining global system wide variables. (global RVs will probably be supported very soon however) Right now you require global variables then you will need to use a database. There are other ways of effectively creating global variables which involves more advanced VB Scripting work (saving info in Registry and/or data files) but just using a database is easiest right now." RvSet seems exactly what I want, thanks. Share this post Link to post
SupportTeam Report post Posted 09/23/2005 08:31 AM "Global RVs" are not something you need to use in this case. Global RVs need only be used if many different lines want to be able to read/set a central globally available variable which is retained by VoiceGuide as long as the software is running and does not get reset when any new calls arrive on any lines. The need to use such global RVs is rare. Share this post Link to post