Page 1 of 1

compare values

Posted: Wed Apr 30, 2014 9:06 pm
by strannik
Hi,
We are in process of valuating Ranorex and we need to compare values in website UI and generated pdf file the values are the same. Each time the system will generate new values for UI and pdf file. Is it possible to give us a code which will check that new generated values are correct.

Re: compare values

Posted: Fri May 02, 2014 3:25 pm
by Support Team
Hello strannik,

With Ranorex it is very easy to compare your values. Ranorex provides some very powerful tools. For example: the RanorexPath allows you to get values from different attributes. But there are also other possibilities to achieve your plan.

In order to get an overview about Ranorex I would suggest to attend to one of our free webinars.
You can find more informations about the webinars by following this link Webinars
In a webinar the important parts of Ranorex will be explained very well.

Kind regards,
Markus (S)

Re: compare values

Posted: Fri May 02, 2014 3:58 pm
by odklizec
I think it would be very hard (if not impossible) to compare GUI values with values stored in PDF file. I would suggest to use Excel xls or csv data file instead. These file formats can be seamlessly used with the existing Ranorex data connectors. PDF is probably the worst choice of format for storing data, which should be further used in your tests.

Re: compare values

Posted: Tue May 06, 2014 10:32 am
by mzperix
Hi strannik,

You can use either user code or Ranorex Studio to make the comparison, if the elments of pdf you age genrating can be identified by Ranorex.

You can check in spy if the pdf structure is recognized by Ranorex.

So in Ranorex studio here are some steps:
1. Identify the webUI element
2. Get the value from the webUI with Get Value action using the identified webUI element.
3. Identify the pdf element
4. Compare the value in pdf with Validate action using the pdf element

If you want this in code, just use make the steps in Ranorex studio, and look at the generated code to have some clues on what to do.

Hope this helps:
Zoltan

Re: compare values

Posted: Wed May 07, 2014 7:35 am
by odklizec
One learns something new every day ;) Using Foxit Reader, and not Adobe Reader, I was not aware it's possible to make the PDF files Accessible. So yes, as you already found in other discussion, it's possible to read and evaluate the PDF content from Ranorex. For future reference, here is the original Ranorex support post describing how to make the PDF files Accessible-friendly...
http://www.ranorex.com/forum/how-to-get ... tml#p18185