A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Automatically name a report when exporting to PDF



 
 
Thread Tools Display Modes
  #1  
Old June 7th, 2010, 05:17 PM posted to microsoft.public.access.reports
shm135
external usenet poster
 
Posts: 26
Default Automatically name a report when exporting to PDF

Hello,

I have a form with a command button that opens my report in print
preview mode in Access 2007. When I click the Export to PDF/XPS
button, the default file name is the name of the actual report within
Access. I've used VBA to change the report caption to match a field on
my form called PROGRAM. However, this does not transfer over when I
want to save my report to pdf.

How can I make it so that when I click export to pdf/xps, the default
file name is named after a text box called PROGRAM?

Please let me know.

Thanks
Ads
  #2  
Old June 7th, 2010, 06:34 PM posted to microsoft.public.access.reports
KenSheridan via AccessMonster.com
external usenet poster
 
Posts: 1,610
Default Automatically name a report when exporting to PDF

I think you'd have to code a command button to do it, using the OutPutTo
method of the DoCmd object. Check out the method in Help for more details.

Ken Sheridan
Stafford, England

shm135 wrote:
Hello,

I have a form with a command button that opens my report in print
preview mode in Access 2007. When I click the Export to PDF/XPS
button, the default file name is the name of the actual report within
Access. I've used VBA to change the report caption to match a field on
my form called PROGRAM. However, this does not transfer over when I
want to save my report to pdf.

How can I make it so that when I click export to pdf/xps, the default
file name is named after a text box called PROGRAM?

Please let me know.

Thanks


--
Message posted via http://www.accessmonster.com

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 06:24 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
Copyright 2004-2018 OfficeFrustration.
The comments are property of their posters.