Excel to Dataset

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi!

I have Excel file as the DataSet for my application, which the user uploads
and the same is stored into the database. The problem is that user put varied
worksheet names for their worksheet. So, how can we read the data from the
Excel and upload the data into the dataset??

Thanks in adavnce

Baren
 
That's half a process issue and half a tech issue.

You may need to set a policy that the worksheet must have the name
"WorksheetX"
....or that there must be exactly one worksheet...

A tech-centric solution may be to have all of the users fill out a specific
Excel Template in order for the upload to work....then create a named range
on one of the worksheets that they have to fill out. That way, it would be
pre-identified.

Whatever process you use (I could think of 3 or 4 other possible scenarios
here) just make sure that as soon as the user uploads it, its validated and,
if you can't read the data, display a message to the user that says what they
have to do to get the thing to work.

Even if the user is a sales person, they'll figure it out the 2nd or third
time the system says, "The workbook you uploaded must have a worksheet names
"WorksheetX"
 
Back
Top