This is a migrated thread and some comments may be shown as answers.

Extract Content from code behind

3 Answers 17 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Mukesh
Top achievements
Rank 1
Mukesh asked on 27 Nov 2013, 01:29 PM
Hi 
I need to extract the content of textcontrol and other control from code behind and store it for later use for comparing in subsequent test cases.
  
I searched all around but didn't get any solution.
  
for the time being I am using following code to extract the content.
  
txtNewcontent = Pages.WebApp.SilverlightApp.TxtCustomtextbox.Text
  
Similarly I am storing all controls data for comparision.
Let me know if there is any better way to do it.

3 Answers, 1 is accepted

Sort by
0
Boyan Boev
Telerik team
answered on 02 Dec 2013, 12:19 PM
Hi Mukesh,

Thank you for contacting us.

Yes this is the only way how you can extract in a code.

Here is an article how you can use extracted variables.

If you would like to create global variables or functions in Test Studio Standalone version that are accessible from all the tests within the test project, you can create a utility class. This class will contain the intended functions or variables.

Also here is how do that without a code.

Hope this helps.

Regards,
Boyan Boev
Telerik
The New Release of Telerik Test Studio Is Here! Download, install,
and send us your feedback!
0
Mukesh
Top achievements
Rank 1
answered on 02 Dec 2013, 12:28 PM
Hi Boyan Boev,

Thanks for the reply and confirmation.
I have already gone through the complete documentation and it is really helpful.
0
Boyan Boev
Telerik team
answered on 02 Dec 2013, 12:42 PM
Hi Mukesh,

Glad to hear that.

If you need additional help, please do not hesitate to contact us.

Regards,
Boyan Boev
Telerik
The New Release of Telerik Test Studio Is Here! Download, install,
and send us your feedback!
Tags
General Discussions
Asked by
Mukesh
Top achievements
Rank 1
Answers by
Boyan Boev
Telerik team
Mukesh
Top achievements
Rank 1
Share this question
or