dotnet_bug:
but i'm getting error :- The type or namespace name 'FileSystem' could not be found (are you missing a using directive or an assembly reference?)
can any one tell me the complete solution???
Hi,
Did your project add reference to 'FileSystem'? If not, I guess you want to create directory using the Directory.CreateDirectory method under System.IO Namespace.
In your case, you can create directory in the server and save the Excel file, which is uploaded, into this directory, and then insert this Excel file's data into database just as Punithkumar replied above. You might need to delete the old data from database before inserting new data.
For more information about creating directory, see http://msdn.microsoft.com/en-us/library/54a0at6s(VS.80).aspx
For more information about uploading file, see http://msdn.microsoft.com/en-us/library/aa479405.aspx
I hope this helps.
Please remember to click ?Mark as Answer? on the post that helps you, and to click ?Unmark as Answer? if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.