• 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.

Thanks.
0
dastrw
Asked:
dastrw
1 Solution
 
Jeffrey CoachmanMIS LiasonCommented:
dastrw,

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:
    Application.Dialogs(xlDialogZoom).Show
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:
    intZoomRatio=ActiveWindow.Zoom

Your Outlook code would look something like this:
    strYourVariable=Me.CurrentMessage.To


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

Check these to books:
http://www.amazon.com/gp/product/1555582869/sr=8-1/qid=1148276490/ref=pd_bbs_1/102-1094311-7186567?%5Fencoding=UTF8
http://www.amazon.com/gp/product/0735614644/ref=pd_bxgy_img_b/104-4892707-5618346?%5Fencoding=UTF8


Good luck!
:)
0
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