-
October 20th, 2010, 12:21 AM
#1
How to read / write Excel file using C#?
I want to read values from excel file and the results should be printed in that same excel file.
I am using VS 2005 and MS Office 2003.
Thanks in Advance!
-
October 20th, 2010, 05:22 AM
#2
Re: How to read / write Excel file using C#?
-
February 12th, 2013, 04:26 AM
#3
Re: How to read / write Excel file using C#?
You can use a 3rd party libraries to work with Excel files in C#. For example you may look for this .Net component.
-
February 20th, 2013, 04:38 AM
#4
Re: How to read / write Excel file using C#?
Workbook book = new Workbook();
book.LoadFromFile("..\\..\\test.xlsx",ExcelVersion.Version97to2003);
book.Worksheets[0].Range["A7"].Value = "abc";
I use an Excel library this project introduces: http://spreadsheet.codeplex.com/
-
February 21st, 2013, 12:53 AM
#5
Re: How to read / write Excel file using C#?
My strategy has been to always avoid excel files like the plague and write CSV (or TSV) files (link) to work with programatically. Alas, that is not always an option. But if, in your case, it is: consider it!
Best Regards,
BioPhysEngr
http://blog.biophysengr.net
--
All advice is offered in good faith only. You are ultimately responsible for effects of your programs and the integrity of the machines they run on.
-
March 22nd, 2013, 05:55 PM
#6
Re: How to read / write Excel file using C#?
There are Excel libs that can be imported to the program - these are standard stuff that are available in the internet and need not be posted in forums unless theres something to discuss CG does not create any languages or software - the MSDN is for that. CG allows one to brainstorm a problem after you've tried.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|