"Save Value"

Ask general questions here.
evildrome
Posts: 3
Joined: Thu Jun 29, 2017 5:19 pm

"Save Value"

Post by evildrome » Thu Jun 29, 2017 5:23 pm

Hi All,

Newbie question...

Ranorex has an action "Get Value" but no "Save Value"

How do I save a value I have retrieved using "Get Value" to a file.

My app is a web app and I am using Ranorex 7.1 (as of today, was 6.0).

Thanks,

Wilson Logan.

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 3914
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: "Save Value"

Post by odklizec » Fri Jun 30, 2017 11:47 am

Hi,

Since Ranorex is built around .Net, you can code almost anything you want. There are several ways how to save things to file, using either C# or VB .Net. Unfortunately, without knowing more details about your use case (what exactly do you want to save and how do you want to use the file), it's hard to suggest something definitive. All I can do is to redirect you to some posts about saving things to file:
https://docs.microsoft.com/en-us/dotnet ... -text-file
https://stackoverflow.com/questions/756 ... e-to-files
https://stackoverflow.com/questions/103 ... in-c-sharp

Eventually, you can use Ranorex own CSV data connector writer...
https://www.ranorex.com/forum/writing-i ... tml#p34657
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration

evildrome
Posts: 3
Joined: Thu Jun 29, 2017 5:19 pm

Re: "Save Value"

Post by evildrome » Fri Jun 30, 2017 3:38 pm

Thank you Pavel,

I had already found the solutions you describe.

I was hoping for a 'native' solution. Not all testers can write VB or C#.

Is it really such a strange thing to want to save output? Clearly it must be or the functionality would be included.

It seems so basic a requirement....

Anyway, thank you for confirming my suspicions.

Cheers,

Wilson.

Vaughan.Douglas
Posts: 250
Joined: Tue Mar 24, 2015 5:05 pm
Location: Des Moines, Iowa, USA

Re: "Save Value"

Post by Vaughan.Douglas » Mon Jul 03, 2017 3:58 pm

evildrome wrote:Thank you Pavel,

I had already found the solutions you describe.

I was hoping for a 'native' solution. Not all testers can write VB or C#.

Is it really such a strange thing to want to save output? Clearly it must be or the functionality would be included.

It seems so basic a requirement....

Anyway, thank you for confirming my suspicions.

Cheers,

Wilson.
I think the problem is "save" isn't clear. Do you want to "save" the value in a parameter to pass it along between modules/test cases? Do you want to "save" the value to output it in a report?

You can see "to save" isn't such a basic requirement at all and depending on your meaning Ranorex has provided different native solutions.
Doug Vaughan

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 3914
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: "Save Value"

Post by odklizec » Tue Jul 04, 2017 8:03 am

Hi Vaughan,

From Wilson's initial post, it seems he just want to write some obtained values to file...
How do I save a value I have retrieved using "Get Value" to a file.
In my opinion, it's better to use a piece of custom code, which can be adapted to whoever specific needs. I don't think that some kind of generic GUI based save-to-file action will suit everyone? Anyway, there can always be created a feature request...
https://uservoice.ranorex.com/forums/15 ... ve-ranorex
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration