United States*
Microsoft.com Home|Site Map
Microsoft*
Search Microsoft.com for:
Help and Support 
|Select a Product|Search (KB)

OL2002: How to Use Option Buttons on an Outlook Form

Article ID:290652
Last Review:February 28, 2004
Revision:1.0
This article was previously published under Q290652

SUMMARY

This article provides an overview of how you can use the OptionButton controls on a Microsoft Outlook custom form.

NOTE: This article does not apply to using option buttons on Microsoft Visual Basic for Applications "UserForms."

MORE INFORMATION

Option buttons provide a way for a user to select one of many options on a form. You can see an example of option buttons if you click the File menu, and then click Archive. The two option buttons are at the top of the dialog box.

There are multiple steps to make option buttons fully functional on an Outlook form. This article describes how to properly bind option buttons to a field so that the setting is preserved when the form is eventually saved or sent to someone else.

The key points to remember are:

All of the option buttons in a set must be bound to the same field. Outlook does this for you automatically when you bind the first option button. If you do not bind the option button to a field, when you send or save the form, the option buttons will be blank.
The field should typically be a Text field, as the example below illustrates. However, you can use other field types that can store multiple values, such as a Number field. Be sure to set the Value of each control to an appropriate value for that particular type of data, such as 0, 1, or 2 for a Number field. Most importantly, do not use a Yes/No, or Boolean, field. These values should be used for check boxes.
The Value of each control should be set to whatever value will be set in the Text field. The Caption of the control typically should match the Value.
If you are using more than one set of option buttons on a form page, you must either put the option buttons in a Frame control. If you do not want the frame visible on the form, you can clear the Frame control's Caption property and set the SpecialEffect property to 0 - Flat.

Steps to Use Option Buttons on a Mail Message

1.Open a new mail message.
2.On the Tools menu, point to Forms, and then click Design This Form.
3.Click the (P.2) tab of the form.
4.On the Form menu, click Control Toolbox.
5.Drag two OptionButton controls from the Control toolbox to the form page.
6.Right-click the first option button, and then click Properties on the shortcut menu.
7.On the Value tab of the Properties window, click New. Type My Color as the name of the field, and then click OK. Note that the field is a Text field. On the Value tab of the Properties window, the Property to use setting should be set to Value. Change the Value setting to Blue.
8.Click the Display tab of the Properties window, and then change the Caption to Blue. This is what will actually appear on the form. Click OK.
9.Right-click the second option button control on the form, and then click Properties on the shortcut menu.
10.On the Value tab of the Properties window, notice that the control is automatically bound to the same field that was created for the first option button. Change the Value to Red.
11.Click the Display tab of the Properties dialog box, change the Caption to Red, and then click OK.
12.Publish the form to the Personal Form Library for testing purposes. To do this, on the Tools menu, point to Forms, and then click Publish Form. Set the Look in field to Personal Forms Library, type Optionbuttons as the name of the form, and then click Publish. When you are asked whether to enable the Save Form Definition with Item setting, click Yes.
13.Close and do not save changes to the form.
To use the form, follow these steps:
1.On the File menu, point to New, and then click Choose Form. Set the Look in field to Personal Forms Library, click the Optionbuttons form, and then click Open.
2.Address the form to yourself.
3.Click the P.2 tab of the form, click the Red option button, and then click Send.
4.Open the item in the Inbox, click the P.2 tab of the form, and you will see that Red is selected. If you enter form design mode and click the All Fields page of the form, you will see that the My Color field contains the value Red.

REFERENCES

For additional information about available resources and answersto commonly asked questions about Microsoft Outlook solutions, click the article number below to view the article in the Microsoft Knowledge Base:
287530 OL2002: Questions About Custom Forms and Outlook Solutions

APPLIES TO
Microsoft Outlook 2002 Standard Edition
Keywords: 
kbhowto KB290652

Article Translations

 

Related Support Centers

Microsoft Outlook 2002

Other Support Options

Contact Microsoft
Phone Numbers, Support Options and Pricing, Online Help, and more.
Customer Service
For non-technical assistance with product purchases, subscriptions, online services, events, training courses, corporate sales, piracy issues, and more.
Newsgroups
Pose a question to other users. Discussion groups and Forums about specific Microsoft products, technologies, and services.

©2005 Microsoft Corporation. All rights reserved. Terms of Use |Trademarks |Privacy Statement