The information in this article applies to:
SUMMARYWhen creating a custom Outlook 98 form, if you bind controls such as the ListBox, CheckBox or OptionButton, the click event in Visual Basic Scripting Edition (VBScript) does not fire. When these controls are not bound, however, the click event is fired. MORE INFORMATION
Microsoft provides programming examples for illustration only, without
warranty either expressed or implied, including, but not limited to, the
implied warranties of merchantability and/or fitness for a particular
purpose. This article assumes that you are familiar with the programming
language being demonstrated and the tools used to create and debug
procedures. Microsoft Support professionals can help explain the functionality
of a particular procedure, but they will not modify these examples to
provide added functionality or construct procedures to meet your specific
needs. If you have limited programming experience, you may want to contact
the Microsoft fee-based consulting line at (800) 936-5200. For more
information about the support options available from Microsoft, please see
the following page on the World Wide Web:
The Click event is often used with command buttons so a specific task can be executed via VBScript code when the user clicks a command button. NOTE: In addition to using command buttons to trigger a VBScript event, you can also use command buttons to display built-in dialog boxes. On a message-type form, for example, command button controls can be bound to a mail field, such as To, CC, or BCC, and the Select Names dialog box appears when the button is clicked. On a custom contact form, the command button can be bound to the Categories, Check Address, or Check Name dialog boxes that are ordinarily available for a contact form. In all of these cases, the appropriate dialog boxes will be displayed without writing VBScript code. Controls other than the command button and label usually allow users to enter information or select an option. These types of controls are typically bound to a field. In these cases, you should use either the Item_PropertyChange() event or the Item_CustomPropertyChange() event, depending on whether the control is bound to a standard Outlook field or a user-defined field, respectively. These events will fire because the value of the underlying field is being changed. For more information about working with the PropertyChange and CustomPropertyChange events, please see the following article in the Microsoft Knowledge Base: Q180857 OL98: Supported Outlook Forms Control EventsThe following sample form demonstrates the click event with a bound and an unbound ListBox control: Creating the Form and Controls
Making ListBox2 Bound
Creating the Form VBScript
REFERENCES
For more information about creating solutions with Microsoft Outlook 98,
please see the following articles in the Microsoft Knowledge Base:
Q180826 OL98: Resources for Custom Forms and Programming Q182349 OL98: Questions About Custom Forms and Outlook Solutions Additional query words: OutSol OutSol98
Keywords : kbdta kbdtacode OffVBS |
Last Reviewed: December 10, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |