I want to print out a one page report with a number of pages choses by an option group called PageNumbers.There i have five options and in each option i have named the number of the pages to be printed.For example the third option is 25 which means that i have to print 25 pages.How can i tie up the command for printing with the option group ? here is my OnClick event :
Dim stDocName As String
stDocName = "rptLabels"
Dim stLinkCriteria As String
stLinkCriteria = "productid = " & Productid
DoCmd.SetWarnings False
DoCmd.OpenReport stDocName, acPreview, , stLinkCriteria
'DoCmd.PrintOut depending on the chosen option ?
Dim stDocName As String
stDocName = "rptLabels"
Dim stLinkCriteria As String
stLinkCriteria = "productid = " & Productid
DoCmd.SetWarnings False
DoCmd.OpenReport stDocName, acPreview, , stLinkCriteria
'DoCmd.PrintOut depending on the chosen option ?