charAt will only return a single character, which you are testing against a
string of characters. For your particular case then you would use subString
as such

Callerinfo.subString(0,2) == "996".

subString(0 = where to start, 2 = where to end) will return the bytes
between and including the start, and end in this case that is 3 bytes as
CallerInfo[0] + CallerInfo[1] + CallerInfo[2]

HTH
Tanner

On Fri, Dec 21, 2012 at 8:48 AM, Chrysostomos Christofi <
ch.christ...@logicom.net> wrote:

>  Hi****
>
> ** **
>
> I use Callerinfo.charAt(0) == "996" in the IF (my calling number starting
> with 996... but unfortunately its not matching****
>
> ** **
>
> I am doing something wrong?****
>
> ** **
>
> *From:* ccie_voice-boun...@onlinestudylist.com [mailto:
> ccie_voice-boun...@onlinestudylist.com] *On Behalf Of *Chrysostomos
> Christofi
> *Sent:* Παρασκευή, 21 Δεκεμβρίου 2012 5:27 μμ
> *To:* Tanner Ezell
>
> *Cc:* Online Study (ccie_voice@onlinestudylist.com)
> *Subject:* Re: [OSL | CCIE_Voice] uccx scripting side****
>
>  ** **
>
> Thanks a lot tanner****
>
>  ****
>
> I will check if its working your propose and I will return back with a
> feedback****
>
>  ****
>
> Regards****
>
> cc****
>
>  ****
>
> *From:* Tanner Ezell [mailto:tanner.ez...@gmail.com<tanner.ez...@gmail.com>]
>
> *Sent:* Παρασκευή, 21 Δεκεμβρίου 2012 4:51 μμ
> *To:* Chrysostomos Christofi
> *Cc:* Online Study (ccie_voice@onlinestudylist.com)
> *Subject:* Re: [OSL | CCIE_Voice] uccx scripting side****
>
>  ****
>
> "5.*" would imply RegEx type of expressions, which may be possible but you
> need to explicitly define that. You're better off doing something like
> myString.charAt(0) == "5" as it should meet your needs quite easily.****
>
>  ****
>
> If you are not using a premium license or are otherwise unable to use the
> java methods you could also use a Menu Step, have two branches, one for "5"
> and one for everything else" and throw a get digit string step under the 5
> branch to collect the rest. ****
>
>  ****
>
> HTH****
>
> Tanner****
>
> On Fri, Dec 21, 2012 at 7:39 AM, Chrysostomos Christofi <
> ch.christ...@logicom.net> wrote:****
>
> Hi Folks****
>
>  ****
>
> I have created a script that will root the call base of caller number:****
>
> I used get call contact info .Its working ok if I set only a specific
> number in the if section****
>
> What I have to config in the callinginfo to match any number starting with
> 5 ? (something like 5!)****
>
>  ****
>
> Attached is the script****
>
>  ****
>
> I used 5.* but its not working****
>
>  ****
>
>  ****
>
> *Regards*****
>
> *Chrysostomos*****
>
>  ****
>
>  ****
>
>
> _______________________________________________
> For more information regarding industry leading CCIE Lab training, please
> visit www.ipexpert.com
>
> Are you a CCNP or CCIE and looking for a job? Check out
> www.PlatinumPlacement.com****
>
>  ****
>
_______________________________________________
For more information regarding industry leading CCIE Lab training, please visit 
www.ipexpert.com

Are you a CCNP or CCIE and looking for a job? Check out 
www.PlatinumPlacement.com

Reply via email to