Validation closed Excel datasheet

Best practices, code snippets for common functionality, examples, and guidelines.
yaro2o
Posts: 95
Joined: Mon Jan 29, 2018 11:19 am

Validation closed Excel datasheet

Post by yaro2o » Mon Jan 29, 2018 11:27 am

Hi, I have a problem with the validation of the introduced variable with the cell in Excel. Is it possible to validate from a closed Excel file, does it have to be open?

The program ultimately generates an excel file, but there is a possibility that it will do bad conversion after the changes.

Is it possible to validate from the loaded sheet to the dataconector ?
Do you know any solution?

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

Re: Validation closed Excel datasheet

Post by odklizec » Tue Jan 30, 2018 10:25 am

Hi,

I'm pretty sure that the Excel file must be somehow loaded for validation. You can either use a built-in Excel data connector to load the file and validate its cells, or you can use a 3rd party solution (MS Interop.Excel, EPPLus .Net lib, etc...). There are many discussions regarding loading Excel and reading/validating its cells.

For validating whole table, check the code samples available here:
https://www.ranorex.com/help/latest/cod ... WholeTable
Of course, you will have to adapt the code to make it working with excel, but the principle should be the same?
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