JBSoccerbrit
10 years agoContributor
Validate String for specific character in a specific position.
Using a keyword test how would you validate that the 10th position of a string is of a specific character, for example.
TxStatus=0&OrderId=100121&CardType=MC&CardSuffix=5454&ApprovalCode=198538
- I would like to assure that the TxStatus= is returning a 0 (the 10th position of the string).
I've looked at aqStringLength and aqStringLength.Get but I am not seeing a way to use these to validate the result.
Thanks,
We managed to resolve this by assigning a variable value like so.
aqString.GetChar(Aliases.browser.wndSOURCE_VIEWER.page32770.RICHEDIT50W.wText,9)
Then doing an IF Then to pull the result of the 9th position in the variable.