View Single Post
  #4  
Old February 2nd 07, 05:05 PM posted to microsoft.public.outlook.program_forms
Sue Mosher [MVP-Outlook]
external usenet poster
 
Posts: 11,651
Default How do I validate a field in a Outlook 2003 Form

Outlook uses properties to store data in items. A control on a custom form can be bound to a custom property, so that data entered into the control is stored in the property, and data in the property is visible in the control. A control can also be unbound. In that case, Outlook discards any data in the control when the item is saved.

The distinction is important for many reasons: Whether a control is bound or unbound determines (a) what event to use to respond to the user's interaction with the control, (b) the best syntax for accessing the data value in the control, (c) whether the data in the control can be used in a validation formula.

The Properties dialog for the control tells you on its first tab the name of the control, and on its second tab, the name of the field, if any, that is bound to the control. We need both pieces of informaton -- the name of the control and the name of the property, if any, that the control is bound to.

Also, since Region is a multi-select combo box, can you give an example of how multiple selections in it would affect the Area box?
--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"Zana" wrote in message ...
Dear Sue,

Thank you for your response. As you are probably aware, from my first email,
I am a novice in this area, therefore I am not sure what you mean by Outlook
custom properties. However, in answer to your second question, both "Region"
and "Area" are Multi-select combo boxes, each of which contains a list of
values. What I am trying to do is make the list of values in the "Area" combo
box dependent on the selection from the "Region" combo box.

Thank you for your help

Zuzana

"Sue Mosher [MVP-Outlook]" wrote:

Some missing info: Are Region and Area the names of Outlook custom properties? Is Area a multi-select combo box since you' talking about it having multiple values? (Can't say that I've ever seen one)

"Zana" wrote in message ...
Hi,

I wonder if you could help me. I am having difficulties with validating
fields in an Outlook 2003 form.

Region: 1l Area: a, b
Region: 2l Area: c, d
Region: 3l Area: e, f

In my form I have created a ComboBox called “Region” containing values 1, 2
and 3. The values in my next ComboBox called “Area” should be dependent on
the value selected in the first ComboBox “Region” e. g. if a user selected
Region “1”, in Area there should be values “a” and “b”, if a user selected
Region “2”, in Area there should be values “c” and “d” and so on…

I would be very grateful if you could help me

Thanks

Zuzana


Ads