Can the content control input box be grey like the old one?

  • Thread starter Thread starter Oakely
  • Start date Start date
O

Oakely

I am looking to get the best of both worlds:

From the new content control tools, I like:
- use "group" instead of "protect" which makes things easier on me and my
users
- can use rich text to give my users more flexibility

From the old forms, I like:
- have the fillable areas greyed out which allows any areas that are left
blank to not show up when the form is printed. With the content control,
there is always the "click here to enter text" which I don't want.

Anyway to have the best of both worlds?

Thanks,

Ryan
 
I am looking to get the best of both worlds:

From the new content control tools, I like:
- use "group" instead of "protect" which makes things easier on me and my
users
- can use rich text to give my users more flexibility

From the old forms, I like:
- have the fillable areas greyed out which allows any areas that are left
blank to not show up when the form is printed. With the content control,
there is always the "click here to enter text" which I don't want.

Anyway to have the best of both worlds?

Thanks,

Ryan

Well, sort of.

With the following two macros, you can change color of the placeholder
text ("click here to enter text", or other wording for other content
control types) to white during printing. The first macro intercepts
the Print command on the Office button menu and its Ctrl+P shortcut,
and the second macro intercepts the Quick Print button that can be put
on the Quick Access Toolbar. See
http://www.gmayor.com/installing_macro.htm if needed.

Sub FilePrint()
Dim cc As ContentControl

' before printing, make placeholder text invisible
For Each cc In ActiveDocument.ContentControls
If cc.ShowingPlaceholderText Then
cc.Range.Font.Color = wdColorWhite
End If
Next

Dialogs(wdDialogFilePrint).Show

' after printing, make placeholder text visible again
For Each cc In ActiveDocument.ContentControls
If cc.ShowingPlaceholderText Then
cc.Range.Font.Color = wdColorAutomatic
End If
Next
End Sub

Sub FilePrintDefault()
Dim cc As ContentControl

' before printing, make placeholder text invisible
For Each cc In ActiveDocument.ContentControls
If cc.ShowingPlaceholderText Then
cc.Range.Font.Color = wdColorWhite
End If
Next

ActiveDocument.PrintOut Background:=False

' after printing, make placeholder text visible again
For Each cc In ActiveDocument.ContentControls
If cc.ShowingPlaceholderText Then
cc.Range.Font.Color = wdColorAutomatic
End If
Next
End Sub

The drawback to this is that, if you're distributing this form to
other users, they may not allow macros to run. You'd need to
distribute the form as a template (*.dotm file) and instruct the users
to store it in their Templates folder, and to use the New command on
the Office button to create a document from it. The only decent
alternative is to digitally sign the macro module with a security
certificate, which costs (much) money.

If macros aren't allowed, the only thing I can think of is to use this
macro once on the form before you distribute it:

Sub SetWhitePlaceholders()
Dim cc As ContentControl

For Each cc In ActiveDocument.ContentControls
cc.Range.Font.Color = wdColorWhite
Next
End Sub

The drawback to this is that all the content controls in an unused
form are invisible unless the user mouses over one or clicks it. Text
or other selections that the user makes will show up as Automatic
color.
 
Back
Top