calling all experts - weird/challenging report

  • Thread starter David Kowalsky via AccessMonster.com
  • Start date
D

David Kowalsky via AccessMonster.com

Hi all,
I have the following problem:
I have an Access 2000 report that contains a few labels and 2 data bound
fields. I need to replace the portion of the report that contains the 2
text boxes with a subreport that would print the two values corresponding
to the 2 fields comming from outside the Access database.

My initial idea was to create a separate report, I dragged it into the
first report after I removed the 2 text boxes and I am stuck at this point
because I don't know how to get those values into this child report. MOST
LIKELY THE TWO VALUES WILL BE TWO OUTPUT PARAMETERS FROM A SQL SERVER
STORED PROCEDURE.

Everything has to be happening in the Print event of the Detail section of
this child report because I need to be able to draw a whole bunch of lines
within this child report.

So, given an access database db1, 2 reports, one of which is embedded
inside the first one, can anyone tell me what code do i have to insert
below so that the whole thing works?
WHAT I NEED TO DO IS REPLACE "1234-1234-12345" and "5678-5678-56789" WITH
TWO PARAMETERS.

Private Sub Detail_Print(Cancel As Integer, PrintCount As Integer)
Me.DrawWidth = 20

Me.Line (200, 600)-(1000, 600)

Me.FontSize = 8
Me.CurrentX = 150
Me.CurrentY = 1200

Me.Print ("1234-1234-12345") 'i need a parameter here

Me.Line (200, 1200)-(1000, 1200)

Me.FontSize = 8
Me.CurrentX = 150
Me.CurrentY = 1200

Me.Print ("5678-5678-56789") 'i need a parameter here

End Sub

Thanks a bunch,
David
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top