• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 349
  • Last Modified:

Programmatically bring up Address List Dialog

I would like to bring up the address list dialog programmatically.  When a user selects someone from the address list,  I would like the information returned to a variable or array.

Can this be done?

In Excel, I can bring up Excel dialogs using:  Application.Dialog(xlDialogZoom), etc.

There doesn't seem to be anything like this in Outlook.

1 Solution
Jeffrey CoachmanMIS LiasonCommented:

Assumming that you could call up the dialog box... you would probably need to access the API to pull the value from the dialog box.

I do not believe that the values contained it the dialog box are "Exposed" to VBA.

For example, the code:
Will, in fact, display the dialog box. But capturing current zoom percent "From the dialog box" is not possible.

You could however "get" the zoom ration through VBA:
    MsgBox ActiveWindow.Zoom
...But not from the dialog box.

You could also set the Zoom ratio in code:
ActiveWindow.Zoom = 200

Again, to accesss the value from the dialog box you would probably have to access the API. You whould have to Access the "AfterUpdate?" event of the dialog box, and caputre the data there.

Or, like in the Excel example, you could get the value through code after the value is being used (When it is present in the message "To..." Box).
Something like this for Excel:

Your Outlook code would look something like this:

My above example is "Air code" so it will not work, but you get the idea.

Check these to books:

Good luck!
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now