VBA: Selected Check Box or Option Button Prints Unselected

Last reviewed: March 16, 1998
Article ID: Q182347
The information in this article applies to:
  • Microsoft Excel 97 for Windows
  • Microsoft PowerPoint 97 for Windows
  • Microsoft Word 97 for Windows
  • Microsoft Windows 95
  • Microsoft Visual Basic for Applications version 5.0

SYMPTOMS

When you print a UserForm, check boxes and option buttons that are selected print as if they are not selected. For example, if a CheckBox control on a UserForm has a check in it (the Value property of the CheckBox control is set to TRUE), the CheckBox control prints without a check in it.

NOTE: This behavior does not occur on Microsoft Windows NT.

WORKAROUND

To work around this issue, create an image of the UserForm by using screen capture, and print this image. For example, to create a screen capture in Microsoft Excel 97, follow these steps:

  1. Start Microsoft Excel 97.

  2. Press ALT+F11 to start the Visual Basic Editor.

  3. On the Insert menu, click UserForm. Draw a CheckBox and a CommandButton control on the UserForm.

  4. With the UserForm selected, press F5 to run the UserForm. Click to select (place a check) in the CheckBox.

  5. Press ALT+PRINT SCREEN. This copies an image of the UserForm to the clipboard.

  6. On the Edit menu, click Paste. The image of the UserForm is pasted into the worksheet.

  7. Click Print on the File menu to print the UserForm.

STATUS

Microsoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article.

       CommandButton. The UserForm is printed.

REFERENCES

For more information about UserForms, from the Visual Basic Editor, click Contents And Index on the Help menu, click the Index tab in Microsoft Excel Help, and type the following text

   UserForm object

and then double-click the selected text to go to the "UserForm object" topic. If you are unable to find the information you need, ask the Office Assistant.


Additional query words: enabled checked chosen select
Keywords : kbprint kbdta OffVBA
Version : WINDOWS:5.0,95,97
Platform : WINDOWS
Issue type : kbbug
Solution Type : kbpending


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: March 16, 1998
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.