Snapshot - Exporting Report to Snapshot

J

Jorge Rite

I am having trouble trying to figure out how to export a report to a
snapshot file via command button. I figure it would look something like
below - but it doesnt work at all...

Sub Snapshot()
Dim rpt As Report

Set rpt = Reports("rptAlpha")

With rpt
.Application.RunCommand acCmdExport
End With

End Sub


Any ideas? Calling rptAlpha via Reports() fails too ... I don't get it
Any help is appreciated!
 
R

Ricky Hicks MVP

Try the OutputTo method ....

DoCmd.OutputTo acReport, "ReportName", "SnapshotFormat(*.snp)",
"C:\FolderName\SubFolderName\FileName.snp"

R. Hicks
 
Top