Ask a Question

How to Edit a Set Variable Value

LRuoc
Occasional Contributor

How to Edit a Set Variable Value

Hello All and thank you for any help.

 

I am scripting against a web application using Keyword Test. What the application does is create a case which results in an incident number then once we have that number I want to store it in a project variable to use it to access the case and process it further.

 

WHen the case is created, it provides me with an incident number, ie "Your incident number is INC111112" I have used a Set Variable Value to pickup this value but it collects the whole string "Your incident number is INC111112" where all I want is "INC111112".

 

Is there a way that I can collect just the INC111112? 

 

TestComplete 14.91
Windows 10
Application - Edge

1 REPLY 1
Marsha_R
Community Hero

You can use Substring from here to pick apart the value in your variable

https://support.smartbear.com/testcomplete/docs/reference/program-objects/aqstring/methods.html


Marsha_R
[Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
cancel
Showing results for 
Search instead for 
Did you mean: