Printing Access reports using VC++ 
Author Message
 Printing Access reports using VC++

I too was wondering how to print a record.

Question: "Do we need to have MSAccess installed on the user's computer
for this method to work? Is it merely necessary for us to copy
MSACC9.OLB to the system directory?"

Thanks a lot.
Waiting for a reply,

Michelle Stone (if possible, please forward your replies to



Quote:
> OK some method from Visual C++  .... Ole Automation

> The type library ( on my machine ) is MSACC8.OLB

> generate the classes from the type library ( View / Class Wizard /
New Class
> / From Type library )
> for the objects _Application, _Reports and _Report.

> the minimal pseudo code would look like this

> COleException oe;

> if ( ! m_application.CreateDispatch("Access.Application", &oe)
> {
>     oe.ReportError();
>     return;
> }

> m_application.NewCurrentDatabase("C:\\Mydb.mdb");
> m_reports.AttachDispatch(m_application.GetReports());
> m_report.AttachDispatch(m_reports.GetItem(1)); // or is the first
report 0 ?
> m_report.Print();

> There are examples in VB code on MSDN which would need to be
translated to
> VC++.


> > Hi there ...

> > I'm working on a database project with the back-end done in MS
Access
> 2000.
> > I want *some* way in which I can print out all those flashy Access
reports
> > using Visual C++. Puhleeeeeze help me out ...

> > Thank you1

Sent via Deja.com http://www.*-*-*.com/
Before you buy.


Sun, 02 Mar 2003 03:00:00 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Printing Access reports using VC++

2. Using VC++ 6.0 as an automation client to view and print reports from MS Access 97

3. Printing Access reports via VC++ programming

4. Printing Access reports via VC++ programming

5. Printing a report using MFC (Unhandled exception error when print previewing)

6. Printing a report using MFC (Unhandled exception error when print previewing)

7. Print Access database report from C++ app?

8. MS Access Reports, Printing and Viewing

9. Creating ActiveX controls to print on MS Access reports

10. Printing MS Access report from MFC program

11. Printing a Access report from a Win Application

12. Printing an Access report

 

 
Powered by phpBB® Forum Software