RunReportAsPDF Windows 7 problem

cagilbert

New member
Local time
Today, 13:30
Joined
Mar 2, 2011
Messages
3
New PC with Win 7 and Office 2010. Others still have XP and 2003. Eric Provencher's RunReportAsPDF is creating the PDF in the wrong folder. Cleared out the PrinterJobControl keys but doesn't seem to affect this. Can't find out where it's getting this folder name from.
Thanks
 
Eric Provencher's RunReportAsPDF is creating the PDF in the wrong folder.

From what I'm seeing, the file path and file name are combined in what you pass to the function (see the part in red):

Code:
Public Function RunReportAsPDF(prmRptName As String, _
                               [COLOR=red][B]prmPdfName[/B][/COLOR] As String) As Boolean

So, however you are calling it, is going to determine where it is going to go.
 
I think that registry setting is used for Reader to find it. I don't think that determines where the Adobe PDF printer creates it. That's what I'm having trouble finding.
 
Or if it is determining where it is being created then, it's not working because I know that the path is what I want for the destination, through debugging, but when I look for the file it's not there, it's somewhere else, always the same place though.
 
Or if it is determining where it is being created then, it's not working because I know that the path is what I want for the destination, through debugging, but when I look for the file it's not there, it's somewhere else, always the same place though.

Where does it end up and what value do you pass to it?

And, it is a good bet that Windows 7 isn't letting it make registry changes. So, you would need to use elevated permissions or set Access to run as administrator.
 
Help!!! Has anyone solved this issue yet? I have had a problem running the "RunReportAsPDF" code since we upgraded to Windowns 7 and Office 2010. SEarching web looking for a solution.:banghead:
 
I ran into the same problem. This link is the solution/workaround I ended up using. The main issue with this method is that you may have to change some of the typefaces or fonts.

New Computer and Save As PDF code no longer saving to specified file name or location
http://www.tek-tips.com/viewthread.cfm?qid=1717276
 
Thanks,- Sxschech, it worked. YOu're a life saver. And to think it was right under my nose all the time. Again, thanks for your help.
 
Glad it worked. I too was frustrated until I found out how to fix it, especially since the only major change was going from 32 bit to 64, all the other software was the same.
 

Users who are viewing this thread

Back
Top Bottom