Do not print command button

J

Jan Kronsell

I'm using Word 2003. I have a document with a command button. When I print
the document the command button is printes as well.

In Excel the Command Button object has an attribute called PrintObject, but
this attribute do not exist for Command Buttons in Word.

In Word 2002 I could avoid printing the Command Button by specifying under
Tools - Settings - Print that Drawing Obejcts should not be printed, but in
2003 the buttons are printed even if I do specify that drawing objects
shalll not be printed.

How do I avoid printing the Comand Button?

Jan
 
J

Jonathan West

Jan Kronsell said:
I'm using Word 2003. I have a document with a command button. When I print
the document the command button is printes as well.

In Excel the Command Button object has an attribute called PrintObject,
but this attribute do not exist for Command Buttons in Word.

In Word 2002 I could avoid printing the Command Button by specifying under
Tools - Settings - Print that Drawing Obejcts should not be printed, but
in 2003 the buttons are printed even if I do specify that drawing objects
shalll not be printed.

How do I avoid printing the Comand Button?


Hi Jan

Take a look here

How to hide a "Print" commandbutton on a document form when
a user clicks on it
http://word.mvps.org/FAQs/TblsFldsFms/HidePrintButton.htm
 
O

Ol

Jan Kronsell said:
I'm using Word 2003. I have a document with a command button. When I print
the document the command button is printes as well.

In Excel the Command Button object has an attribute called PrintObject, but
this attribute do not exist for Command Buttons in Word.

In Word 2002 I could avoid printing the Command Button by specifying under
Tools - Settings - Print that Drawing Obejcts should not be printed, but in
2003 the buttons are printed even if I do specify that drawing objects
shalll not be printed.

How do I avoid printing the Comand Button?

Jan

That macro will open copy of your document without macrobuttons.

Sub PrintedCopy()
Dim aShape As InlineShape
Dim Doc1 As Document
ActiveDocument.Range.Copy
Documents.Add
Set Doc1 = Documents(1)
Doc1.Range.Paste
For Each aShape In Doc1.InlineShapes
aShape.Delete
Next aShape
Doc1.Activate
End Sub
 
J

Jan Kronsell

Thank you. That did the trick. Do you know by any chance why the difference
beteween commandbuttons in Word and Excel? Or is it just a MS thing?

Jan
 
R

R. Frerichs

"Jonathan West" wrote:

I posted this in an earlier thread and decided I had better put it here.

I went to the word.mvps.org page and followed the directions for the
nonprinting commandbutton. However, I can't get it to work in the protected
mode. When click the button, focus shifts to the first form field. If I
don't have it protected, it works but then all my form field get deleted when
typing is done. Any more suggestions?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top