Hi friends,
I don't know how to open, read and write to excel sheet with C code
This is a discussion on How to access excel sheet with C program(open,read,write) within the C Programming forums, part of the General Programming Boards category; Hi friends, I don't know how to open, read and write to excel sheet with C code...
Hi friends,
I don't know how to open, read and write to excel sheet with C code
Take a look at microsoft sites.
Learn C++ (C++ Books, C Books, FAQ, Forum Search)
Code painter latest version on sourceforge DOWNLOAD NOW!
Download FSB Data Integrity Tester.
Siavosh K C
Probably the same way that this other poster was after MS .DOC files
fopen and fclose functions
exactly as that thread said, there is a lot of additional formatting
involved with document types other than .txt, but i found that
you can write to an excel file just as you write to a text file, using
fprintf. your ability to control excel from within a C program is
fairly limited unless you learn how to program formatting info in
as well (which would be quite complex), but if you had a program
that needed to log outputs for some calculation, i found that you
can write to a spreadsheet - \n will move your destination cell to
the one below the current cell, \t will move it to the cell on the
right. this may be somewhat useful to you, but as far as reading
in from a spreadsheet in C, you're on your own
No No's:
fflush (stdin); gets (); void main ();
Goodies:
Example of fgets (); The FAQ, C/C++ Reference
My Gear:
OS - Windows XP
IDE - MS Visual C++ 2008 Express Edition
ASCII stupid question, get a stupid ANSI
I agree, given than excel can readily import tab or comma separated data from text files (I've done this many times), the amount of work it would take to generate a .xls file manually (without Microsoft's API) seems prohibitive.