Printing Subforms - URGENT

G

Guest

I have a subform that contains a pivotchart and have a print command button
on the main form to print the subform, When I print the subform shows the
pivotchart with the defalut values and not the changes made from the current
view. How can I print the subform showing the pivotchart with the current
view/selections.

Thanks in advance,

Dave
 
A

AlCamp

Dave,
Sounds like you changed some data in the subform but when you printed,
the new data did not show.
Try a Refresh before you print.
hth
Al Camp

PS: Adding "URGENT" to your question has no effect on response time.
Someone will answer as soon as possible...
 
G

Guest

Al,

What command line to I add? Here is what I have now.

Private Sub Command29_Click()
On Error GoTo Err_Command29_Click

Dim stDocName As String
Dim MyForm As Form

stDocName = "TopLevel subform"
Set MyForm = Screen.ActiveForm
DoCmd.SelectObject acForm, stDocName, True
DoCmd.PrintOut
DoCmd.SelectObject acForm, MyForm.Name, False

Exit_Command29_Click:
Exit Sub

Err_Command29_Click:
MsgBox Err.Description
Resume Exit_Command29_Click

End Sub

Thanks,

Dave
 
A

AlCamp

Dave,
Sorry, but I haven't ever used the PrintOut method, so I don't want to
speculate on what the problem is.
But, I would imagine that you need to adjust the PrintOut "arguments"
([printrange][, pagefrom, pageto]... etc) in order to get the page you're on
(the one you just edited).

The Refresh I referred to would go right after the button click...
Private Sub Command29_Click()
REFRESH
but I would guess that that's not the primary problem. (give it a try...
can't hurt.)

Try a new post, with your code included, and whether this is just one record
out of many (ex. record 10 of 200).
Someone should respond...

Al Camp
 

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