Quantcast
Channel: Excel Data Reader - Read Excel files in .NET
Viewing all articles
Browse latest Browse all 448

New Post: Default name for columns with no name

$
0
0
I have a .xlsx file where only some of the columns in row 1 has names. The columns with no name is automatically named 'Column?' (This is both Caption and ColumnName).
I have previously used Excel by opening as a database via oledb and where these columns were automatically named 'F?'. No I have a backward compatibility problem because of this.
This is giving me problems as I do not feel I can just rename Column? to F? because I cannot seem to differentiate between a column actually named Column2 and one which was internally named Column2 because no name is specified in the spreadsheet.

So basically I have two questions;
  1. Is is possible to change the default behavior of this auto naming of columns with no name? Basically exchange 'Column' with 'F'
  2. Or is possible to tell if column didn't actually have a name (was blank). Then I can write the logic myself.
Thanks in advance :)

Viewing all articles
Browse latest Browse all 448

Trending Articles