Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Printing curently selected record with Master/Detail

Status
Not open for further replies.

MarkoKobal

IS-IT--Management
Jul 18, 2001
14
SI
Hi. I have a master/detail form (order form with order items in detail) and I would like to print out the report based on this curently selected form. How? I saw a similar tip but it doesn't work:

Dim stDocName As String
Dim LinkFilter As String

LinkFilter = "recordID = " & Me!recordId
stDocName = <your report name>
DoCmd.OpenReport stDocName, acviewnormal, , LinkFilter

What should I put for recordID ? the primary key of curently selected record?

 
What you need is a report that is based on a query that contains both master and detail information.
You absolutely need to use the report's Grouping Options in order to have a convenient report layout.
Happy programming!

F.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top