Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Outlook / Programming Forms / August 2004

Tip: Looking for answers? Try searching our database.

Listbox in Custom Form

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
kaykayit - 22 Jul 2004 20:41 GMT
I have modified the Contacts form to include 3 listboxes.  
Two listboxes uses PossibleValues property to populate and
the third listbox has 2 columns and uses a two dimensional
array to populate.  All listboxes are bound to 3 different
keywords fields.  I have added the listboxes on page 2 of
the form.  I have also added a textbox for each listbox on
the 1st page of the form and bound to the same field of
each listbox.  I used a button on the first page to set
focus to the corresponding listbox on the second page.  
Everything works fine when creating a new contact.  
However, once the contact is saved, the listbox populated
by an array does not show all of the values in the array.  
It only shows the values that are selected and not all the
items in the array.
Please help.
Thanx
Sue Mosher [MVP-Outlook] - 22 Jul 2004 21:33 GMT
Sounds like you're doing something to one-off the form, which means it will
never run code again so the Item_Open event handler doesn't run again to
populate list #3 . Using PossibleValues in code to populate the list boxes
is one known cause. See http://www.outlookcode.com/d/formpub.htm#oneoff for
others.

Signature

Sue Mosher, Outlook MVP
Author of
    Microsoft Outlook Programming - Jumpstart for
    Administrators, Power Users, and Developers
    http://www.outlookcode.com/jumpstart.aspx

> I have modified the Contacts form to include 3 listboxes.
> Two listboxes uses PossibleValues property to populate and
[quoted text clipped - 12 lines]
> Please help.
> Thanx
kaykayit - 28 Jul 2004 23:48 GMT
I have removed any code that lists possible values.
Instead, I have used arrays to populate all the
listboxes.  Yet the problem persists.  I also had a
reference to SetCurrentFormPage and I removed this. I am
still having the original problem.  When I look at the
Values tab in the listbox properties, even when I use an
array it still lists the values in Possible Values.

>-----Original Message-----
>Sounds like you're doing something to one-off the form, which means it will
[quoted text clipped - 21 lines]
>
>.
Sue Mosher [MVP-Outlook] - 29 Jul 2004 00:09 GMT
Have you checked the status of the "send form definition with item" box?
Republished the form with an incremented version number?

If you set the possible values manually in an early design of the form,
they'll be on the controls until you remove them. They are not a cause of
one-offing.

Signature

Sue Mosher, Outlook MVP
Author of
    Microsoft Outlook Programming - Jumpstart for
    Administrators, Power Users, and Developers
    http://www.outlookcode.com/jumpstart.aspx

> I have removed any code that lists possible values.
> Instead, I have used arrays to populate all the
[quoted text clipped - 14 lines]
> http://www.outlookcode.com/d/formpub.htm#oneoff for
> >others.

> >"kaykayit" <anonymous@discussions.microsoft.com> wrote in
> message
[quoted text clipped - 26 lines]
> >
> >.
kaykayit - 11 Aug 2004 23:37 GMT
Thanks Sue for your response.
I have tried creating a new form with the list boxes and
still have the same problem.

>-----Original Message-----
>Have you checked the status of the "send form definition with item" box?
[quoted text clipped - 55 lines]
>
>.
Sue Mosher [MVP-Outlook] - 12 Aug 2004 01:15 GMT
Where is the form published? Did you check items created with the new form
for the obvious symptoms of one-offing -- larger size and the MessageClass
reverting to the base class? What about the "send form definition with item"
box?

Signature

Sue Mosher, Outlook MVP
Author of
    Microsoft Outlook Programming - Jumpstart for
    Administrators, Power Users, and Developers
    http://www.outlookcode.com/jumpstart.aspx

> Thanks Sue for your response.
> I have tried creating a new form with the list boxes and
[quoted text clipped - 60 lines]
> >> the
> >> >> items in the array.
kaykayit - 12 Aug 2004 19:41 GMT
The form is published in the Organizational Forms
directory.  The "send form definition with item" was never
checked on any version of the form.  As for the
MessageClass I don't know where to look to check for the
symptoms.  I tried creating a new form again but still
have the same issues.

>-----Original Message-----
>Where is the form published? Did you check items created with the new form
[quoted text clipped - 68 lines]
>
>.
Sue Mosher [MVP-Outlook] - 12 Aug 2004 20:01 GMT
You can add the Message Class field to any view.

Signature

Sue Mosher, Outlook MVP
Author of
    Microsoft Outlook Programming - Jumpstart for
    Administrators, Power Users, and Developers
    http://www.outlookcode.com/jumpstart.aspx

> The form is published in the Organizational Forms
> directory.  The "send form definition with item" was never
[quoted text clipped - 11 lines]
> definition with item"
> >box?

> >"kaykayit" <anonymous@discussions.microsoft.com> wrote in
> message
[quoted text clipped - 74 lines]
> >> >> the
> >> >> >> items in the array.
kaykayit - 18 Aug 2004 16:14 GMT
Thanks Sue so much for your help.  I deleted the all
versions of the forms from the Public Folder and cleared
the cache and now Item_Open runs everytime.  Now I have
the opposite problem.  The items previously selected in
the listbox are cleared when reopening the Contact Item.  
Is there a way to save the selection?

>-----Original Message-----
>You can add the Message Class field to any view.
[quoted text clipped - 95 lines]
>
>.
Sue Mosher [MVP-Outlook] - 18 Aug 2004 16:47 GMT
Either bind the listbox to an Outlook keywords property or write code in
Item_Write to save the data to an Outlook property as a delimited list, plus
code in Item_Open to use the information from that property to set the
selections.

Signature

Sue Mosher, Outlook MVP
Author of
    Microsoft Outlook Programming - Jumpstart for
    Administrators, Power Users, and Developers
    http://www.outlookcode.com/jumpstart.aspx

> Thanks Sue so much for your help.  I deleted the all
> versions of the forms from the Public Folder and cleared
> the cache and now Item_Open runs everytime.  Now I have
> the opposite problem.  The items previously selected in
> the listbox are cleared when reopening the Contact Item.
> Is there a way to save the selection?
kaykayIT - 18 Aug 2004 17:37 GMT
The listboxes are each bound to different keyword properties.  I am trying to
use the information from the keywords to set the selections.

> Either bind the listbox to an Outlook keywords property or write code in
> Item_Write to save the data to an Outlook property as a delimited list, plus
[quoted text clipped - 7 lines]
> > the listbox are cleared when reopening the Contact Item.
> > Is there a way to save the selection?
Sue Mosher [MVP-Outlook] - 18 Aug 2004 18:14 GMT
If the listboxes are bound to keywords properties, they should automatically
show the selected items. Does it work if you take out the code you're using
to set the selections?

Signature

Sue Mosher, Outlook MVP
Author of
    Microsoft Outlook Programming - Jumpstart for
    Administrators, Power Users, and Developers
    http://www.outlookcode.com/jumpstart.aspx

> The listboxes are each bound to different keyword properties.  I am trying
> to
[quoted text clipped - 5 lines]
>> code in Item_Open to use the information from that property to set the
>> selections.

>> > Thanks Sue so much for your help.  I deleted the all
>> > versions of the forms from the Public Folder and cleared
>> > the cache and now Item_Open runs everytime.  Now I have
>> > the opposite problem.  The items previously selected in
>> > the listbox are cleared when reopening the Contact Item.
>> > Is there a way to save the selection?
kaykayIT - 18 Aug 2004 19:31 GMT
I've tried the easy way of binding the listboxes to a keywords property.  
That does not work.  Is there some comprehensive Guide to VBScripting.  I am
feeling my way through the dark.  I am very acquainted with VBA and somewhat
acquainted with VB but it seems the scripting is a different concept.

> Either bind the listbox to an Outlook keywords property or write code in
> Item_Write to save the data to an Outlook property as a delimited list, plus
[quoted text clipped - 7 lines]
> > the listbox are cleared when reopening the Contact Item.
> > Is there a way to save the selection?
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.