C# .NET - Bulk Upload - Asked By rama chandran on 26-Mar-13 06:10 AM

Hi Friends,

i am using asp.net with c#, in my application i want to do 1 functionality.

i want to upload a excel sheet that contains bulk of datas with more than 5 columns and when click on submit button the datas in that excel sheet should be saved in database sqlserver without duplication. please send me the full coding for this.


Regards,
Ram
Robbe Morris replied to rama chandran on 26-Mar-13 09:54 AM
You really need to purchase a thread safe component for working with Excel like spreadsheetgear.com.  Excel is NOT suited for multi-user environments like IIS/Web Server and is clearly stated by Microsoft itself.  You are going to experience constant Excel.exe process hangs if you don't.

The syntax for using spreadsheetgear is virtually identical to the Excel object model.  Here is an old article that explains how to use Excel in C#.

http://www.eggheadcafe.com/tutorials/ado/fbdf47ec-be61-448c-afd3-09e15a0e357c/net-message-queue-with-excel-xml-and-adonet.aspx