A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Combining reports



 
 
Thread Tools Display Modes
  #1  
Old May 20th, 2004, 04:50 PM
Mac
external usenet poster
 
Posts: n/a
Default Combining reports

I have about 2 dozen reports which need to be printed either seperately or
all together. Seperately they are fine but I want to combine them without
duplicating the whole lot on one massive report.

Is it possible to create a report which can call and add each report in turn
via vba?

This would save masses of time and avoid potential problems from subreport
events.

Thanks
Mac.


  #2  
Old May 20th, 2004, 10:05 PM
Fons Ponsioen
external usenet poster
 
Posts: n/a
Default Combining reports

You can combine several reports in the on click event of a
print button on a form, simply replicate the
stDocName = "Report1"
DoCmd.OpenReport stDocName, acNormal
in the onclick event procedure.
Hope this helps
-----Original Message-----
I have about 2 dozen reports which need to be printed

either seperately or
all together. Seperately they are fine but I want to

combine them without
duplicating the whole lot on one massive report.

Is it possible to create a report which can call and add

each report in turn
via vba?

This would save masses of time and avoid potential

problems from subreport
events.

Thanks
Mac.


.

  #3  
Old May 21st, 2004, 09:43 AM
Mac
external usenet poster
 
Posts: n/a
Default Combining reports

The reports are used via a webservice/dll so there is no form or buttons to
click as such.
The reports are opened and closed using office xp interop assemblies passing
in my parameters which are collected in the Report_Open event of each
report. The report is opened and a snp file generated using the following
code
appAccess.DoCmd.OpenReport(reportName,Access.AcVie w.acViewPreview,
System.Reflection.Missing.Value, System.Reflection.Missing.Value,
Access.AcWindowMode.acHidden, MyParameterID)

appAccess.DoCmd.OutputTo(Access.AcOutputObjectType .acOutputReport,
reportName, Access.Constants.acFormatSNP, outputFile, false, null, null);


An simplified example of a typical report_open event is below.

Private Sub Report_Open(Cancel As Integer)
Dim ReviewID As String
Dim sp As ADODB.Recordset
ReviewID = Reports![Report7].OpenArgs
Me.RecordSource = " exec aCash " & ReviewID
End Sub

I would like to use the following in a Report_Open event to open each report
for my 'all in one' but I don't know how to go from opening the report to
inserting it into the current report so I can combine them all.

DoCmd.OpenReport "PageCoverSheet", acViewPreview, , , acHidden, ReviewID


Thanks
Mac.


"Fons Ponsioen" wrote in message
...
You can combine several reports in the on click event of a
print button on a form, simply replicate the
stDocName = "Report1"
DoCmd.OpenReport stDocName, acNormal
in the onclick event procedure.
Hope this helps
-----Original Message-----
I have about 2 dozen reports which need to be printed

either seperately or
all together. Seperately they are fine but I want to

combine them without
duplicating the whole lot on one massive report.

Is it possible to create a report which can call and add

each report in turn
via vba?

This would save masses of time and avoid potential

problems from subreport
events.

Thanks
Mac.


.



  #4  
Old May 21st, 2004, 02:01 PM
Fons Ponsioen
external usenet poster
 
Posts: n/a
Default Combining reports

I have never used webserve/dll. What I would suggest is
re-post an give the below description, I think you will
get some responses.
Good Luck
Fons
-----Original Message-----
The reports are used via a webservice/dll so there is no

form or buttons to
click as such.
The reports are opened and closed using office xp interop

assemblies passing
in my parameters which are collected in the Report_Open

event of each
report. The report is opened and a snp file generated

using the following
code
appAccess.DoCmd.OpenReport

(reportName,Access.AcView.acViewPreview,
System.Reflection.Missing.Value,

System.Reflection.Missing.Value,
Access.AcWindowMode.acHidden, MyParameterID)

appAccess.DoCmd.OutputTo

(Access.AcOutputObjectType.acOutputReport,
reportName, Access.Constants.acFormatSNP, outputFile,

false, null, null);


An simplified example of a typical report_open event is

below.

Private Sub Report_Open(Cancel As Integer)
Dim ReviewID As String
Dim sp As ADODB.Recordset
ReviewID = Reports![Report7].OpenArgs
Me.RecordSource = " exec aCash " & ReviewID
End Sub

I would like to use the following in a Report_Open event

to open each report
for my 'all in one' but I don't know how to go from

opening the report to
inserting it into the current report so I can combine

them all.

DoCmd.OpenReport "PageCoverSheet", acViewPreview, , ,

acHidden, ReviewID


Thanks
Mac.


"Fons Ponsioen"

wrote in message
...
You can combine several reports in the on click event

of a
print button on a form, simply replicate the
stDocName = "Report1"
DoCmd.OpenReport stDocName, acNormal
in the onclick event procedure.
Hope this helps
-----Original Message-----
I have about 2 dozen reports which need to be printed

either seperately or
all together. Seperately they are fine but I want to

combine them without
duplicating the whole lot on one massive report.

Is it possible to create a report which can call and

add
each report in turn
via vba?

This would save masses of time and avoid potential

problems from subreport
events.

Thanks
Mac.


.



.

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 04:35 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.