1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

Macro to Save Word as PDF?

Discussion in 'Business Applications' started by Jamoatwork, Jan 9, 2006.

Thread Status:
Not open for further replies.
Advertisement
  1. Jamoatwork

    Jamoatwork Thread Starter

    Joined:
    Jan 9, 2006
    Messages:
    9
    I work in an office with some "stupid" people so need to write a macro that will convert word (2003) .doc files to .pdf (Adobe Acrobat 6.0 Professional) when they go to save these important documents. Is this possible & how do i use the macro? I know it is possible to select it as a print option but they aren't able to ;)
    Any help would be more then welcome.(y)
     
  2. OBP

    OBP

    Joined:
    Mar 8, 2005
    Messages:
    19,896
    I do not think the people in your office are quite as "stupid" as you think. Have you tried manually saving a word document as a .pdf file?
    I am not a Word person, but from memory of my office you have to "convert" a Word document with Adobe.
     
  3. Jamoatwork

    Jamoatwork Thread Starter

    Joined:
    Jan 9, 2006
    Messages:
    9
    Yes, I know how to "convert" the word .doc to a .pdf but i need it to do it automatically so anyone who uses the template has to save it as a .pdf. Is this possible? My boss seems to think so.
     
  4. Datalyss

    Datalyss Banned

    Joined:
    Dec 8, 2005
    Messages:
    381
    Just tell 'em to use the Writer in OpenOffice. One click...hello PDF. It's free. ;)
     
  5. Jamoatwork

    Jamoatwork Thread Starter

    Joined:
    Jan 9, 2006
    Messages:
    9
    Don't think my boss will agree to that but I can always ask. I take it there is no "macro"/ command option to solve my problem then. I knew my boss was fibbing when he told me it should be "easy".
     
  6. kiwiguy

    kiwiguy

    Joined:
    Aug 17, 2003
    Messages:
    17,584
    Trying to get in between the Save option to interpose a third party application would be difficult for a Macro I believe. While it may be possible to have a VB routine place a button on the toolbar, that is really no different to the Print button you have now, if they cannot (will not) use that, I don't see any easy way of automating it.
     
  7. bomb #21

    bomb #21

    Joined:
    Jul 1, 2005
    Messages:
    8,546
    I tend to agree with OBP in one sense -- if some people in your office are so stupid that they cannot follow "these files must be saved as PDF"-type instructions, I begin to wonder what the person who recruited them was thinking of. :confused:

    That aside, "Working with events" at http://word.mvps.org/FAQs/index.htm (under Macros/VBA), including "Intercepting events like Save and Print", may give some pointers.

    HTH,
    Andy
     
  8. Datalyss

    Datalyss Banned

    Joined:
    Dec 8, 2005
    Messages:
    381
    I don't see why your boss wouldn't agree. Like I said, it's free. All you gotta do is type your document, and click the [PDF] button on the toolbar. It's that simple.
     
  9. kiwiguy

    kiwiguy

    Joined:
    Aug 17, 2003
    Messages:
    17,584
    Regretably there is not a 100% compatability with Microsoft Office and OpenOffice.

    Its close, but no cigar (yet).

    In my field, I could use it but the small formatting anomalies would create some annoying and time consuming difficulties. Particularly as all clients use MS Word, Access and Excel.
     
  10. Datalyss

    Datalyss Banned

    Joined:
    Dec 8, 2005
    Messages:
    381
    Like what? I'm just curious.

    Anyway, importing existing docs might indeed have a few snags, but I would guess that typing new stuff, and exporting directly to PDF would be no trouble.
     
  11. kiwiguy

    kiwiguy

    Joined:
    Aug 17, 2003
    Messages:
    17,584
    Odd things like image placements and formats are "close" but not always exactly as they were in the original Word document.

    The spreadsheet has problems with the size of some analysis work as well, only Office 2003 can reliably handle a 200 MB sheet I have found. Even earlier Excel versions struggle.
    But OO spreadsheetonly goes to 32,000 rows, which means its just not useable for 90% of my work.

    As I drat a lot of regulatory documents in conjunction with others, we all need to use the same package as a base. There is no room for any inconsistencies or the cost quickly outweighs the "free" nature of OO.
     
  12. bomb #21

    bomb #21

    Joined:
    Jul 1, 2005
    Messages:
    8,546
    "Calc" in version 2 goes to 65536, if that helps. :)
     
  13. Jamoatwork

    Jamoatwork Thread Starter

    Joined:
    Jan 9, 2006
    Messages:
    9
    Glad to see my thread has been hjacked
     
  14. JFresh

    JFresh

    Joined:
    Jun 11, 2004
    Messages:
    161
    I'm just going to toss in my two cents here given my experience with this.

    I know that Adobe Standard Edition 7.0, when installed also installs a "printer" called "Adobe PDF" printer. Assuming you're working with Adobe 7, and assuming that Professional (the upgrade to Standard) would have this as well and that it is indeed installed (to find out go to Start | Settings | Printers & Faxes and it should be listed among your installed printers there).

    Assuming all is well from here, here's how to record your macro:

    1. Open Word 2003 and open any document you want.

    2. Tools | Macro -> Record New Macro

    3. At this point a window pops up. Click on the Toolbars button

    4. Now you'll see a new window with two lists side by side. On the right list, it will say something like "Normal.NewMacro.Macro1". Click and drag that where you want it on the tool bar and it will become a button at that point. Also, make sure that on the bottom it states "Normal.dot" this is the default toolbar setup that every person using Word is given. If you use a custom toolbar template for your users, your boss should be able to provide that info.

    5. Right click on the button and a menu will come down allowing you to change the name or the image (edit allows you to make your own and change offers premade choices)

    6. From here be ready to start your macro as after this step all of your actions will be recorded:

    7. Click on the close window and you'll see the scary face to show that your macro is now being recorded. Click on File | Print and change your printer to "Adobe PDF". Now click on OK.

    8. You'll now be given a new window asking you what to name the file and where to save it (defaulted to My Documents). Rename the file and click on save and your Word document will be automatically converted, saved, and opened in Adobe Professional.

    9. At this point go back to Word and stop the macro. Test it to make sure it goes over OK.


    I hope that helps!

    JFresh
     
  15. TonyJollans

    TonyJollans

    Joined:
    Jun 24, 2004
    Messages:
    114
    JFresh is correct - if you have a full Acrobat you will have "Adobe PDF" or similar set up as a printer and it is relatively easy to write a macro to 'print' a document to PDF.

    The difficult bit is dealing with the Acrobat Dialog which presents (step 8 in JFresh's post) asking for the name (and location) of the pdf file you want to create - this is part of Acrobat and beyond the reach of a macro in Word - and nothing will record from it. I believe, in Acrobat 7, there is a setting in Acrobat to tell it always to take the default instead of prompting for the name - I'm not sure about earlier releases but will do some digging to see if I can find out.
     
  16. Sponsor

As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Loading...
Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/432546

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice