0

I'm parsing an Excel file, with multiple columns and 2 rows:
first row is the column title, and the second row is for a user default value.
for example:

|   |  A   |       B        |  C   |
------------------------------------
| 1 |  ID  |      Name      | Room |
------------------------------------
| 2 |  0   |choose-from-list|  1   |

Since I want user to choose B2 value from list of options, I configured a data validation rule, and chose a range of values from another sheet.
So when I read the Validation property:

var cellDataValidation = cell.Validation;

The value of Formula1 is:

"=Sheet2!$A$2:$A$7"

The question is (finally): how can I use that expression, and get those cells from anther sheet (without regexp tricks, but using excel API).

Soner Gönül
  • 97,193
  • 102
  • 206
  • 364
RoeeK
  • 1,112
  • 12
  • 23
  • Something like [this](http://stackoverflow.com/questions/11320626/does-excel-have-a-built-in-method-for-parsing-formulas-ie-to-obtain-a-list-of)? – Zev Spitz Dec 02 '15 at 14:06
  • well, he didn't find an answer, or indeed there is no API way. Moreover, I'm not quite sure how to find that range in another sheet – RoeeK Dec 02 '15 at 14:23
  • Try using Named range values that could do the trick :) – Linga Dec 04 '15 at 11:29

0 Answers0