cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
749
Views
10
Helpful
2
Replies

UCCX How to set variable to match selected digit in DNIS (or other Get Call Contact Info result)?

sjhrhaskell
Level 1
Level 1

Hey gang,

 

I'm looking for a way to set the value of a variable to match a specific digit of "Original Called Number" as returned by the Get Call Contact Info step.  It's pretty easy to set the variable to match the whole thing of course, but what if I want it to match, say, just the 4th digit? 

 

For example, caller dials 202-123-9999.  I want to set the variable named "FourthDigit" to match the 4th number of the called number, in this case, "1".  

 

Any ideas?

Thanks!

1 Accepted Solution

Accepted Solutions

Chris Deren
Hall of Fame
Hall of Fame

You can use the <variable>.substring(6,9) option to get the last 4 digits from 10 digit number.

View solution in original post

2 Replies 2

Chris Deren
Hall of Fame
Hall of Fame

You can use the <variable>.substring(6,9) option to get the last 4 digits from 10 digit number.

That put me on the right track, thanks Chris!  To clarify a bit more, since I wanted to get the value of a specific digit, I used adjacent index numbers, like so:

 

Set DNIS3rdDigit = DNIS.substring(2,3)