none
Outlook Combobox does not populate RRS feed

  • Question

  • I have added ComboBox in my Outlook calendar appointment message class. When I'm in developer mode and run the form, this VB code works correctly. But when I'm creating a new calendar event with my custom message class, the ComboBox is empty. I think the VB code won't run.

    Sub Item_Open()
    	Dim myComboBox
    	
    	Set myComboBox = Item.GetInspector.ModifiedFormPages("Ohjelmatiedot").Controls("ComboBox1")
    	myComboBox.AddItem("Gates, Bill")
    	myComboBox.AddItem("Ballmer, Steve")
    	myComboBox.AddItem("Test")
    End Sub

    Wednesday, September 28, 2016 3:01 PM

Answers

All replies

  • Hello,

    Are you sure the message class is not a standard one? Try to save the item and then re-open it anew, or just open an existing item with a custom message class which corresponds to your form. Does it work in that case?

    Did you customize the compose page as well as read page separately?

    Also I have noticed the following line of code:

    Set myComboBox = Item.GetInspector.ModifiedFormPages("Ohjelmatiedot").Controls("ComboBox1")

    Try to break the chain of property and method calls and declare them on separate lines of code. Thus, you may find what property or method exactly fails (If any).


    [custom.development]

    Wednesday, September 28, 2016 4:07 PM
  • I'm sure that message class is not a standard because I see all my custom fields, when creating a new event or editing existing event.

    I have created a new tab (page?). I have not touched the default tabs.

    Can you give me an example, how to break the chain?

    --

    Also I found another way to populate ComboBox from its properties. Still this way would be more developer friendly, than very long string separate with semicolons in small text input.

    Wednesday, September 28, 2016 4:16 PM
  • Are macros allowed to run in Trust Center?

    Also try to allow scripts for Public Folders, in Trust Center.


    [custom.development]


    Wednesday, September 28, 2016 4:30 PM
  • Allowing scripts for Shared Folders in Trust Center solve this problem.

    Thank you Eugene!

    • Proposed as answer by David_JunFeng Thursday, September 29, 2016 1:52 AM
    • Marked as answer by David_JunFeng Wednesday, October 5, 2016 1:36 PM
    Wednesday, September 28, 2016 4:44 PM
  • Good news! Thank you for letting me know.

    [custom.development]

    Wednesday, September 28, 2016 6:05 PM