Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Programming / March 2006

Tip: Looking for answers? Try searching our database.

Using VB to Convert Single Worksheet to PDF then Email?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
golf4wff@hotmail.com - 24 Mar 2006 07:25 GMT
Hi, everyone -

I know it's been a long time, but I thought I'd jump back in with a
doozie that I've been struggling with. I  've included a small bit of
code below that is a small part of a much larger strip. Basically, what
I use this bit for is to send a copy of one worksheet, out of a much
larger income calculation spreadsheet, to a staff person.

It works really slick, but I have one problem: when the staff person
gets the email and opens the copies single worksheet, it gives a couple
messages about wanting to update the formulas in the worksheet itself.
I'm thinking, to eliminate these messages, I'm hoping there is a way to
modify my code that that, maybe, after ActiveSheet.Copy, I can convert
the worksheet to a pdf..... then finish out the code. Has anyone had
any success in doing this before?

Code:

If Sheets("Data_Entry_Sheet").[k107] > "" Then
Sheets("FSS_Worksheet").Unprotect ("led52not")
Sheet20.Select
ActiveSheet.Copy
ActiveWorkbook.SendMail Recipients:="jdoe@wvpha.org", Subject:=" FSS
Escrow Sheet"
ActiveWorkbook.Close False

ActiveSheet.Shapes("object 6.wav").Select 'fss reminder msg'
Selection.Verb Verb:=xlPrimary

MyTimer = Timer
Do
Loop While Timer - MyTimer < 4

paperwarning = MsgBox("I HAVE HEARD THE REMINDER MESSAGE AND PROMISE,
UPON PENALTY OF SOMETHING REALLY BAD HAPPENING, THAT I WILL PASS ON
ACCOUNTING'S COPY OF THE FSS WORKSHEET TO THE APPROPRIATE STAFF
PERSON.", vbOKOnly, "REMEMBER TO PROPERTLY DISTRIBUTE COPIES OF FSS
WORKSHEETS!!!")
Sheets("FSS_Worksheet").Protect ("led52not")
Sheet2.Select
[a1].Select
Sheets("data_entry_sheet").Protect ("led52not")

Thanks to everyone for the help.

Take care.

Golf
golf4wff@hotmail.com - 25 Mar 2006 05:50 GMT
Just wanted to see if I could bump this one up a little......  Thanks
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.