Saving a report in SNP format - problem

PortyAL

Craigavon, N.Ireland
Local time
Today, 04:16
Joined
Apr 16, 2007
Messages
24
Hi

I use the routine below to create and save a snapshot file of a report ("rep recommendations"). The file location is determined by the path name entered in [Document folder] in the form [frm recommendations]. The name of the file is determined by the value in [job] on the same form.


Code:
Sub expap()

Dim APLocation As String

APLocation = Forms![frm recs tracked jobs]![Document folder] & "\" & Forms![frm recommendations]![Job] & " Action Plan.snp"


DoCmd.OutputTo acOutputReport, "rep recommendations", acFormatSNP, APLocation

End Sub

All works well if [document folder] is a text field. If it is a hyperlink field then I get the following error

"Run-time error 2024. The report snapshot was not created because you don't have enough free disk space for temporary work files."

I would like to keep [document folder] as a hyperlink field as it is a handy link to all files in relation to a job.

I tried using a calculated field i.e. StrConv([document folder],2) but I got the same error when I used the calculated field in the code above.

Any advice would be appreciated.

Thanks

AL
 
Hi

Got it sorted. Used the following calculated field in the code:

HyperlinkPart([document folder],1)

AL
 

Users who are viewing this thread

Back
Top Bottom