?
Solved

Automate printing selected sections in a protected Word form

Posted on 2008-06-23
2
Medium Priority
?
243 Views
Last Modified: 2010-04-21
Hi,

I am using MS Word 2003.  I have created a protected form with several pages and sections.  I have a section towards the middle of the form that contains internet links and instructions about the form.   I would prefer that this section doesn't print when the completed form is printed by the users.  I know that you can include or exclude sections and pages using the print form page range feature.  But, is there a way to exclude this section automatically (maybe using some VB code) so that my users don't have to be reminded to use the page range feature to exclude this section?

Thanks.
0
Comment
Question by:Delano29
2 Comments
 
LVL 9

Accepted Solution

by:
JonMny earned 2000 total points
ID: 21848578
You could use the before print to set the range.

Public WithEvents oApp As Word.Application


Private Sub oApp_DocumentBeforePrint(ByVal Doc As Document, Cancel As Boolean)
'add code to set range here
End Sub


see link

http://word.mvps.org/faqs/macrosvba/AppClassEvents.htm
0
 

Author Closing Comment

by:Delano29
ID: 31469806
Thanks for pointing me in the right direction.  I'll look into the info. in the link as well and do some experimenting.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Q&A with Course Creator, Mark Lassoff, on the importance of HTML5 in the career of a modern-day developer.
The SignAloud Glove is capable of translating American Sign Language signs into text and audio.
Learn how to make your own table of contents in Microsoft Word using paragraph styles and the automatic table of contents tool. We'll be using the paragraph styles in Word’s Home toolbar to help you create a table of contents. Type out your initial …
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question