Thanks. Yes, that works. However, when I do that I now have two Calendar
controls and a List View control that shrink of their own volition. I've not
been able to figure out why these controls do that. Any ideas?
If there isn't a method or property to determine whether a form is opened in
design or run time I'll have to code a run-time error and use the Err code to
execute the Item_Open code I want to run conditionally. I know this is ugly,
but it'll work.
Thanks.
> You can hold down the Shift key to prevent the form from running code when opening it in design mode.
>
[quoted text clipped - 12 lines]
> >
> > Thanks for your help.
You can probably check by using CommandBars, since certain commands are visible and enabled in form design mode that shouldn't otherwise be available.
I generally avoid using any controls on forms that don't come with Outlook itself. You might have to include code to set those controls' UI properties.

Signature
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
> Thanks. Yes, that works. However, when I do that I now have two Calendar
> controls and a List View control that shrink of their own volition. I've not
[quoted text clipped - 23 lines]
>> >
>> > Thanks for your help.
Culverin - 29 Aug 2006 19:21 GMT
Good idea about the CommandBars.
I have code to set the UI properties; which is why I need it to run in
design mode in the Item_Open but not the version check code.
Thanks a bunch.
> You can probably check by using CommandBars, since certain commands are visible and enabled in form design mode that shouldn't otherwise be available.
>
[quoted text clipped - 27 lines]
> >> >
> >> > Thanks for your help.
Culverin - 30 Aug 2006 14:00 GMT
The "Form Design" bar is not visible at run time. I tried to use the visible
property of the object in the Item_Open function to determine whether the
form is opening in design or run time. It didn't work because the visible
property is still false when the Item_Open is executing. Similarly, the
Layout menu is not visible at run time. I tried using the Controls.Count
property as well but both design and run time counts were 9. I can only
conclude from this that the initial properties of the CommandBars are set
after the Item_Open executes.
When do these CommandBar changes occur? Obviously, the form knows it's
being opened in design mode and sets certain properties differently than at
run time. What executes after Item_Open and is it accessible
programatically? Alternatively, is there a property that can be referenced
in the Item_Open function that will allow me to tell the difference between
design and run?
Thanks.
> You can probably check by using CommandBars, since certain commands are visible and enabled in form design mode that shouldn't otherwise be available.
>
[quoted text clipped - 27 lines]
> >> >
> >> > Thanks for your help.