By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,665 Members | 1,363 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,665 IT Pros & Developers. It's quick & easy.

Print content of sub form only

P: n/a
Hi All,
I'm stuck, so....... In Access97 I have a form which has a
subform(setup as a continous form), after a user selects several things
on the form the subform gets requeryed and displays the content
approperiate to the selections the user made. Now, the user wants to
print the sub-form only.
I've tried putting a print button on the sub-form and have tried both
'docmd.printout' and 'docmd.printout acSelection' in the on click
event of the button on the sub-form and both do a print out that is
just a screen print which is not what I want . I also do not want to
create a report/recordsource sql string that looks like this subform.
Any other ideas or vba code?
thanks
bobh.

Nov 13 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
<vu******@isp.com> wrote
. . .
I've tried putting a print button on the
sub-form and have tried both 'docmd.printout'
and 'docmd.printout acSelection' in the
on click event of the button on the sub-form
and both do a print out that is just a screen
print which is not what I want.
What _do_ you want/expect? With that information, perhaps we could help.
I also do not want to create a report/
recordsource sql string that looks like
this subform.


Might I ask "Why not?" Almost always, the best way to print information is
to do so using a report.

Larry Linson
Microsoft Access MVP

Nov 13 '05 #2

P: n/a
I was hoping to not having to create a report cause then I would have
to create a querydef which contained the users selections and then
open/print the report using the modified query as its source.
I was just hoping since I had the subform displayed with the correct
information in it I could just have it print.
But I have resolved this issue by doing just that; create a
report(subform look-alike) with a query as its source, user makes
selections on the form, create a SQL string and pass it to the query as
a querydef, open/print the report.
bobh.

Nov 13 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.