adding columns to excel with dao & vc++ 
Author Message
 adding columns to excel with dao & vc++

Hello:
I was wondering if anyone knows how (if it's even possible) to add
new columns to an excel spreadsheet within a Visual C++ program.
I am able to open the excel document with the CDaoDatabase class
and I can use the CDaoRecordset class to get row information, but
I cannot figure out how to add columns (or fields) to the spreadsheet.
I have tried using the CDaoTableDef class, and it works if I only try to
get information about fields that currently exist, but I am not having any
luck getting it to create new fields.  Can anyone help me out here?
Thanks!
-Dan


Tue, 22 Jul 2003 10:09:31 GMT  
 adding columns to excel with dao & vc++
Quote:

> I was wondering if anyone knows how (if it's even possible) to add
> new columns to an excel spreadsheet within a visual C++ program.

I doubt you can do it the way you have tried.
You could control Excel via Automation and add columns that way.

Bill Manville
MVP - Microsoft Excel, Oxford, England
No email replies please - reply in newsgroup



Fri, 25 Jul 2003 09:26:30 GMT  
 adding columns to excel with dao & vc++
Or maybe ADO.NET can do that.

- Chu


Quote:

> > I was wondering if anyone knows how (if it's even possible) to add
> > new columns to an excel spreadsheet within a visual C++ program.

> I doubt you can do it the way you have tried.
> You could control Excel via Automation and add columns that way.

> Bill Manville
> MVP - Microsoft Excel, Oxford, England
> No email replies please - reply in newsgroup



Fri, 25 Jul 2003 13:55:54 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. adding columns to excel with dao & vc++

2. exe(vc++) & Excel

3. How can I display a DAO record set as a multi column list VC++

4. VC 4.2, DAO & Office 97 problem

5. DAO & Indexes - Adding records/Current record

6. Need to add a column to my database file from VC++

7. Need to add a column to my database file from VC++

8. Accessing Excel file & Excel file format

9. Adding columns to ListView after it's been added to a form

10. VC++ & DAO for VB Question

11. Accessing versions of Access using VC++ & DAO

12. Freeze Datagrid column like Ms Excel

 

 
Powered by phpBB® Forum Software