Word Form - Disable printing of non-enabled checkbox fields


Post new topic   General Reply to Topic (not reply to a specific post)    Forums Home -> User Forms RSS
Next:  Determining class of IP address  
Author Message
CJ
External


Since: Jul 11, 2007
Posts: 4



PostPosted: Wed Jul 11, 2007 9:37 am    Post subject: Word Form - Disable printing of non-enabled checkbox fields
Archived from groups: microsoft>public>word>vba>userforms (more info?)

I have a form designed with a list of five items with a checkbox beside each
item. I need the ability for the end user to choose any or all of the five
checkboxes however, if they only choose the first and the fourth items
listed on the checkbox list, I do not want the second, third, or fifth item
to print. Is there a way to get the form to NOT print those items not
enabled (checkmarked)? If so, albeit not as important, is there a way to
then close the gap of white space left when those items do not print? (If
requested, I can send a Word file sample of the document I am trying to do
this with.)

Thank you for any assistance you can offer. (Running Windows XP, Office
2003 SP2)
-CJ
Back to top
Russ
External


Since: Oct 02, 2005
Posts: 19



PostPosted: Wed Jul 11, 2007 12:16 pm    Post subject: Re: Word Form - Disable printing of non-enabled checkbox fields [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

CJ,
I think you are talking about formfields in a document and not userform
dialogs. One way to not print something without a gap in a document is to
create bookmarks for those areas and make all text font and paragraph marks
between the text in those bookmarked areas hidden. As long as an option in
Word to print hidden text is not check, which it isn't by default, then the
gaps should close. It's up to you to design the document in a way that it
still looks good with those areas hidden. You may have to temporarily
unprotect the document, if we are talking about a document with formfiels,
to make those bookmarked areas hidden. When you go into Print Preview mode
you should see how the document will look when printed.
If you are talking about mail merge, then it might be handled differently.

> I have a form designed with a list of five items with a checkbox beside each
> item. I need the ability for the end user to choose any or all of the five
> checkboxes however, if they only choose the first and the fourth items
> listed on the checkbox list, I do not want the second, third, or fifth item
> to print. Is there a way to get the form to NOT print those items not
> enabled (checkmarked)? If so, albeit not as important, is there a way to
> then close the gap of white space left when those items do not print? (If
> requested, I can send a Word file sample of the document I am trying to do
> this with.)
>
> Thank you for any assistance you can offer. (Running Windows XP, Office
> 2003 SP2)
> -CJ
>
>

--
Russ

drsmN0SPAMikleAThotmailD0Tcom.INVALID
Back to top
CJ
External


Since: Jul 11, 2007
Posts: 4



PostPosted: Wed Jul 11, 2007 12:16 pm    Post subject: Re: Word Form - Disable printing of non-enabled checkbox fields [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Thanks Russ for your prompt response. Can you direct me to the correct user
group? I was not aware that a userform is not a form utilizing form fields
or control toolbox. I also understand your response below on hiding text
(and am aware of how to do that) however, I am not the one that will be
choosing which options to print and which ones not to print. I'm a legal
assistant and I am trying to create a legal addendum to a contract for use
in the field. In as simple terms as I can, I'll give the example below of a
form I'm trying to create.
________________________________________________________________________________
ADDENDUM
Preamble Text - This addendum is between Us and Customer and modifies the
contract as follows:

[checkbox1] Section Xx is hereby modified to blah blah
[checkbox2] Section N is hereby modified to blah blah
[checkbox3] Section Y is hereby modified to blah blah

Closing terms of agreement and signatures.
__________________________________________________________________________________

Now if the user selects the first option and the third option, is there a
way to have the second option not print? Or if they only choose one of the
amended options, is there a way to not have the other options print? They
should have the ability to choose any (or all) the options that apply to
their specific customer. I also tried a listbox which I could almost get to
work however, several of the options are 300 characters in length and don't
fit in a listbox.

Thanks again!
-CJ


"Russ" <drsN0SPAMmikle DeleteThis @hotmailD0Tcom.INVALID> wrote in message
news:C2BA7AB8.1AEFE%drsN0SPAMmikle@hotmailD0Tcom.INVALID...
> CJ,
> I think you are talking about formfields in a document and not userform
> dialogs. One way to not print something without a gap in a document is to
> create bookmarks for those areas and make all text font and paragraph
> marks
> between the text in those bookmarked areas hidden. As long as an option in
> Word to print hidden text is not check, which it isn't by default, then
> the
> gaps should close. It's up to you to design the document in a way that it
> still looks good with those areas hidden. You may have to temporarily
> unprotect the document, if we are talking about a document with formfiels,
> to make those bookmarked areas hidden. When you go into Print Preview mode
> you should see how the document will look when printed.
> If you are talking about mail merge, then it might be handled differently.
>
>> I have a form designed with a list of five items with a checkbox beside
>> each
>> item. I need the ability for the end user to choose any or all of the
>> five
>> checkboxes however, if they only choose the first and the fourth items
>> listed on the checkbox list, I do not want the second, third, or fifth
>> item
>> to print. Is there a way to get the form to NOT print those items not
>> enabled (checkmarked)? If so, albeit not as important, is there a way to
>> then close the gap of white space left when those items do not print?
>> (If
>> requested, I can send a Word file sample of the document I am trying to
>> do
>> this with.)
>>
>> Thank you for any assistance you can offer. (Running Windows XP, Office
>> 2003 SP2)
>> -CJ
>>
>>
>
> --
> Russ
>
> drsmN0SPAMikleAThotmailD0Tcom.INVALID
>
Back to top
Russ
External


Since: Oct 02, 2005
Posts: 19



PostPosted: Wed Jul 11, 2007 11:06 pm    Post subject: Re: Word Form - Disable printing of non-enabled checkbox fields [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

CJ,
These are the Microsoft word forums:

microsoft.public.word.application.errors
microsoft.public.word.conversions
microsoft.public.word.customization.menustoolbars
microsoft.public.word.docmanagement
microsoft.public.word.drawing.graphics
microsoft.public.word.formatting.longdocs
microsoft.public.word.international.features
microsoft.public.word.internet.assistant
microsoft.public.word.macword2001
microsoft.public.word.macword5-6
microsoft.public.word.macword98
microsoft.public.word.mail
microsoft.public.word.mailmerge.fields
microsoft.public.word.newusers
microsoft.public.word.numbering
microsoft.public.word.oleinterop
microsoft.public.word.pagelayout
microsoft.public.word.printingfonts
microsoft.public.word.programming
microsoft.public.word.setup.networking
microsoft.public.word.spelling.grammar
microsoft.public.word.tables
microsoft.public.word.vba.addins
microsoft.public.word.vba.beginners
microsoft.public.word.vba.customization
microsoft.public.word.vba.general
microsoft.public.word.vba.userforms
microsoft.public.word.web.authoring
microsoft.public.word.word6-7macros
microsoft.public.word.word97vba

If you don't want to use vba, I'd suggest posing 'your not print' question
to mailmerge.fields, pagelayout, docmanagement.

To pose the same question to more than one group, use a comma between each
group name in the 'To:' field:

microsoft.public.word.docmanagement,microsoft.public.word.mailmerge.fields,
microsoft.public.word.pagelayout

Otherwise, I think for those documents you'd have to use vba code to
intercept the print command to hide parts of the text before printing.
I don't know a lot about mail-merge, but I think it could be set up to not
print empty fields.
> Thanks Russ for your prompt response. Can you direct me to the correct user
> group? I was not aware that a userform is not a form utilizing form fields
> or control toolbox. I also understand your response below on hiding text
> (and am aware of how to do that) however, I am not the one that will be
> choosing which options to print and which ones not to print. I'm a legal
> assistant and I am trying to create a legal addendum to a contract for use
> in the field. In as simple terms as I can, I'll give the example below of a
> form I'm trying to create.
> ______________________________________________________________________________
> __
> ADDENDUM
> Preamble Text - This addendum is between Us and Customer and modifies the
> contract as follows:
>
> [checkbox1] Section Xx is hereby modified to blah blah
> [checkbox2] Section N is hereby modified to blah blah
> [checkbox3] Section Y is hereby modified to blah blah
>
> Closing terms of agreement and signatures.
> ______________________________________________________________________________
> ____
>
> Now if the user selects the first option and the third option, is there a
> way to have the second option not print? Or if they only choose one of the
> amended options, is there a way to not have the other options print? They
> should have the ability to choose any (or all) the options that apply to
> their specific customer. I also tried a listbox which I could almost get to
> work however, several of the options are 300 characters in length and don't
> fit in a listbox.
>
> Thanks again!
> -CJ
>
>
> "Russ" <drsN0SPAMmikle.DeleteThis@hotmailD0Tcom.INVALID> wrote in message
> news:C2BA7AB8.1AEFE%drsN0SPAMmikle@hotmailD0Tcom.INVALID...
>> CJ,
>> I think you are talking about formfields in a document and not userform
>> dialogs. One way to not print something without a gap in a document is to
>> create bookmarks for those areas and make all text font and paragraph
>> marks
>> between the text in those bookmarked areas hidden. As long as an option in
>> Word to print hidden text is not check, which it isn't by default, then
>> the
>> gaps should close. It's up to you to design the document in a way that it
>> still looks good with those areas hidden. You may have to temporarily
>> unprotect the document, if we are talking about a document with formfiels,
>> to make those bookmarked areas hidden. When you go into Print Preview mode
>> you should see how the document will look when printed.
>> If you are talking about mail merge, then it might be handled differently.
>>
>>> I have a form designed with a list of five items with a checkbox beside
>>> each
>>> item. I need the ability for the end user to choose any or all of the
>>> five
>>> checkboxes however, if they only choose the first and the fourth items
>>> listed on the checkbox list, I do not want the second, third, or fifth
>>> item
>>> to print. Is there a way to get the form to NOT print those items not
>>> enabled (checkmarked)? If so, albeit not as important, is there a way to
>>> then close the gap of white space left when those items do not print?
>>> (If
>>> requested, I can send a Word file sample of the document I am trying to
>>> do
>>> this with.)
>>>
>>> Thank you for any assistance you can offer. (Running Windows XP, Office
>>> 2003 SP2)
>>> -CJ
>>>
>>>
>>
>> --
>> Russ
>>
>> drsmN0SPAMikleAThotmailD0Tcom.INVALID
>>
>
>

--
Russ

drsmN0SPAMikleAThotmailD0Tcom.INVALID
Back to top
Doug Robbins - Word MVP
External


Since: Jul 14, 2006
Posts: 2538



PostPosted: Thu Jul 12, 2007 2:35 am    Post subject: Re: Word Form - Disable printing of non-enabled checkbox fields [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Insert a bookmark around section of the text that you might want deleted and
have a macro that contains the following code run on exit from the
associated checkbox

With ActiveDocument
.Unprotect
If .FormFields("Check1").CheckBox.Value = False Then
.Bookmarks ("CheckBox1Text").Range.Font.Hidden=True
Else
.Bookmarks("CheckBox1Text").Range.Font.Hidden=False
End If
.Protect wdAllowOnlyFormFields, NoReset
End With

Under Tools>Options>View, you will want to have the display of Hidden Text
enabled so that the user can go back and change their selection and under
Tools>Options>Print, make sure that the box for Hidden Text is unchecked so
that text that is so formatted does not print.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"CJ" <LonestarCJ.TakeThisOut@nospam.com> wrote in message
news:uVwmGt9wHHA.600@TK2MSFTNGP05.phx.gbl...
> Thanks Russ for your prompt response. Can you direct me to the correct
> user group? I was not aware that a userform is not a form utilizing form
> fields or control toolbox. I also understand your response below on
> hiding text (and am aware of how to do that) however, I am not the one
> that will be choosing which options to print and which ones not to print.
> I'm a legal assistant and I am trying to create a legal addendum to a
> contract for use in the field. In as simple terms as I can, I'll give the
> example below of a form I'm trying to create.
> ________________________________________________________________________________
> ADDENDUM
> Preamble Text - This addendum is between Us and Customer and modifies the
> contract as follows:
>
> [checkbox1] Section Xx is hereby modified to blah blah
> [checkbox2] Section N is hereby modified to blah blah
> [checkbox3] Section Y is hereby modified to blah blah
>
> Closing terms of agreement and signatures.
> __________________________________________________________________________________
>
> Now if the user selects the first option and the third option, is there a
> way to have the second option not print? Or if they only choose one of
> the amended options, is there a way to not have the other options print?
> They should have the ability to choose any (or all) the options that apply
> to their specific customer. I also tried a listbox which I could almost
> get to work however, several of the options are 300 characters in length
> and don't fit in a listbox.
>
> Thanks again!
> -CJ
>
>
> "Russ" <drsN0SPAMmikle.TakeThisOut@hotmailD0Tcom.INVALID> wrote in message
> news:C2BA7AB8.1AEFE%drsN0SPAMmikle@hotmailD0Tcom.INVALID...
>> CJ,
>> I think you are talking about formfields in a document and not userform
>> dialogs. One way to not print something without a gap in a document is to
>> create bookmarks for those areas and make all text font and paragraph
>> marks
>> between the text in those bookmarked areas hidden. As long as an option
>> in
>> Word to print hidden text is not check, which it isn't by default, then
>> the
>> gaps should close. It's up to you to design the document in a way that it
>> still looks good with those areas hidden. You may have to temporarily
>> unprotect the document, if we are talking about a document with
>> formfiels,
>> to make those bookmarked areas hidden. When you go into Print Preview
>> mode
>> you should see how the document will look when printed.
>> If you are talking about mail merge, then it might be handled
>> differently.
>>
>>> I have a form designed with a list of five items with a checkbox beside
>>> each
>>> item. I need the ability for the end user to choose any or all of the
>>> five
>>> checkboxes however, if they only choose the first and the fourth items
>>> listed on the checkbox list, I do not want the second, third, or fifth
>>> item
>>> to print. Is there a way to get the form to NOT print those items not
>>> enabled (checkmarked)? If so, albeit not as important, is there a way
>>> to
>>> then close the gap of white space left when those items do not print?
>>> (If
>>> requested, I can send a Word file sample of the document I am trying to
>>> do
>>> this with.)
>>>
>>> Thank you for any assistance you can offer. (Running Windows XP, Office
>>> 2003 SP2)
>>> -CJ
>>>
>>>
>>
>> --
>> Russ
>>
>> drsmN0SPAMikleAThotmailD0Tcom.INVALID
>>
>
>
Back to top
CJ
External


Since: Jul 11, 2007
Posts: 4



PostPosted: Thu Jul 12, 2007 7:50 am    Post subject: Re: Word Form - Disable printing of non-enabled checkbox fields [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

I'll give it a shot or at least my best attempt Smile THANKS for your
response and for applying pieces of your time to these forums helping
everyone!
-CJ

"Doug Robbins - Word MVP" <dkr DeleteThis @REMOVECAPSmvps.org> wrote in message
news:%23VFMo$CxHHA.4612@TK2MSFTNGP04.phx.gbl...
> Insert a bookmark around section of the text that you might want deleted
> and have a macro that contains the following code run on exit from the
> associated checkbox
>
> With ActiveDocument
> .Unprotect
> If .FormFields("Check1").CheckBox.Value = False Then
> .Bookmarks ("CheckBox1Text").Range.Font.Hidden=True
> Else
> .Bookmarks("CheckBox1Text").Range.Font.Hidden=False
> End If
> .Protect wdAllowOnlyFormFields, NoReset
> End With
>
> Under Tools>Options>View, you will want to have the display of Hidden Text
> enabled so that the user can go back and change their selection and under
> Tools>Options>Print, make sure that the box for Hidden Text is unchecked
> so that text that is so formatted does not print.
>
> --
> Hope this helps.
>
> Please reply to the newsgroup unless you wish to avail yourself of my
> services on a paid consulting basis.
>
> Doug Robbins - Word MVP
>
> "CJ" <LonestarCJ DeleteThis @nospam.com> wrote in message
> news:uVwmGt9wHHA.600@TK2MSFTNGP05.phx.gbl...
>> Thanks Russ for your prompt response. Can you direct me to the correct
>> user group? I was not aware that a userform is not a form utilizing form
>> fields or control toolbox. I also understand your response below on
>> hiding text (and am aware of how to do that) however, I am not the one
>> that will be choosing which options to print and which ones not to print.
>> I'm a legal assistant and I am trying to create a legal addendum to a
>> contract for use in the field. In as simple terms as I can, I'll give
>> the example below of a form I'm trying to create.
>> ________________________________________________________________________________
>> ADDENDUM
>> Preamble Text - This addendum is between Us and Customer and modifies the
>> contract as follows:
>>
>> [checkbox1] Section Xx is hereby modified to blah blah
>> [checkbox2] Section N is hereby modified to blah blah
>> [checkbox3] Section Y is hereby modified to blah blah
>>
>> Closing terms of agreement and signatures.
>> __________________________________________________________________________________
>>
>> Now if the user selects the first option and the third option, is there a
>> way to have the second option not print? Or if they only choose one of
>> the amended options, is there a way to not have the other options print?
>> They should have the ability to choose any (or all) the options that
>> apply to their specific customer. I also tried a listbox which I could
>> almost get to work however, several of the options are 300 characters in
>> length and don't fit in a listbox.
>>
>> Thanks again!
>> -CJ
>>
>>
>> "Russ" <drsN0SPAMmikle DeleteThis @hotmailD0Tcom.INVALID> wrote in message
>> news:C2BA7AB8.1AEFE%drsN0SPAMmikle@hotmailD0Tcom.INVALID...
>>> CJ,
>>> I think you are talking about formfields in a document and not userform
>>> dialogs. One way to not print something without a gap in a document is
>>> to
>>> create bookmarks for those areas and make all text font and paragraph
>>> marks
>>> between the text in those bookmarked areas hidden. As long as an option
>>> in
>>> Word to print hidden text is not check, which it isn't by default, then
>>> the
>>> gaps should close. It's up to you to design the document in a way that
>>> it
>>> still looks good with those areas hidden. You may have to temporarily
>>> unprotect the document, if we are talking about a document with
>>> formfiels,
>>> to make those bookmarked areas hidden. When you go into Print Preview
>>> mode
>>> you should see how the document will look when printed.
>>> If you are talking about mail merge, then it might be handled
>>> differently.
>>>
>>>> I have a form designed with a list of five items with a checkbox beside
>>>> each
>>>> item. I need the ability for the end user to choose any or all of the
>>>> five
>>>> checkboxes however, if they only choose the first and the fourth items
>>>> listed on the checkbox list, I do not want the second, third, or fifth
>>>> item
>>>> to print. Is there a way to get the form to NOT print those items not
>>>> enabled (checkmarked)? If so, albeit not as important, is there a way
>>>> to
>>>> then close the gap of white space left when those items do not print?
>>>> (If
>>>> requested, I can send a Word file sample of the document I am trying to
>>>> do
>>>> this with.)
>>>>
>>>> Thank you for any assistance you can offer. (Running Windows XP,
>>>> Office
>>>> 2003 SP2)
>>>> -CJ
>>>>
>>>>
>>>
>>> --
>>> Russ
>>>
>>> drsmN0SPAMikleAThotmailD0Tcom.INVALID
>>>
>>
>>
>
>
Back to top
Display posts from previous:   
Post new topic   General Reply to Topic (not reply to a specific post)    Forums Home -> User Forms All times are: Eastern Time (US & Canada) (change)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum