NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

character comparison

I have a string in TestStand that contains letters and numbers; is there a way of comparing each character within the string to see whether it is either a [A..Z] or a [0..9]?

 

 

 

0 Kudos
Message 1 of 4
(4,481 Views)

Here is a hacky solution.  You might be better going to a code module or creating your own step type.

 

Just a thought.

jigg
CTA, CLA
testeract.com
~Will work for kudos and/or BBQ~
Message 2 of 4
(4,396 Views)

Thanks for that, it works well.

I dont understand the 65//A & 90//Z though; "//" is normally a comment; what is this function, it does not appear to be listed in my version of TestStand but works anyway?

0 Kudos
Message 3 of 4
(4,371 Views)

You can put just 65.  // is a comment.  I put it so that you knew 65 was A.  I'm just used to commenting code so if I ever come back I will know what it means.

 

Glad it worked.

 

Regards,

jigg
CTA, CLA
testeract.com
~Will work for kudos and/or BBQ~
0 Kudos
Message 4 of 4
(4,365 Views)