Consider this Report_Open() event handler ...
Private Sub Report_Open(Cancel As Integer)
Const FN As String = "frmYourChart"
Dim filespec As String
filespec = CurrentProject.path & "\ImageName.gif"
DoCmd.OpenForm FN, acFormPivotChart, , , , acHidden
Forms(FN).ChartSpace.ExportPicture filespec, "gif", 950, 625
DoCmd.Close acForm, FN
Me.Image0.Picture = filespecMSDN ExportPicture() Reference
End Sub
No comments:
Post a Comment