VoiceGuide IVR Software Main Page
Jump to content

Vbs Validation Of Entered Numbers

Recommended Posts

I copied this script from help to validate if entered numbers begins with 0 and takes long about 11.

 

set vg = CreateObject("VoiceGuide.CommandLink")

iLen = Len("$RV_ENTEREDNUMBER")

sFirstChar = Left("$RV_ENTEREDNUMBER",1)

if iLen<10 or iLen>11 or sFirstChar <> "0" then

sResult = "verify_failed"

else

sResult = "verify_passed"

end i

vg.Run_ResultReturn $RV_LINEID, sResult

set vg = Nothing

 

 

after entering numbers I got debug error on vg program

that in the line 8 char 5 (or sometimes other char)

 

"If expected".

 

error code= here some numbers.

 

 

Is the script wrong?

 

I am working on windows 2000 server. Do I have to install some additional soft from microsoft to make server understand vbs from vg?

Share this post


Link to post

Just look at line 8 of your script, it says:

end i

This is invalid syntax - you should have used just "end" on this line. The error message even tells you that the problem ocurrs on the 5th character of the line...

Share this post


Link to post

Yes, quite correct, it should actually be "end if". Will fix the help file as well.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×