Results 1 to 2 of 2
2007-07-06, 10:35 #1
- Join Date
- Mar 2003
- Cardiff, Wales
- Thanked 0 Times in 0 Posts
Open file dialog from custom form (Outlook 2003)
Subject edited by HansV to be more descriptive than just 'Outlook'
We have designed a custom form which contains a list box in which attachments are displayed.
We want to be able to place a command button next to the box which will open the attach file dialog rather than users having to use the toolbar button.
Can somebody tell me what the code is to achieve this.
2007-07-06, 13:20 #2
- Join Date
- Dec 2000
- Salt Lake City, Utah, USA
- Thanked 6 Times in 6 Posts
Re: Open file dialog from custom form (Outlook 2003)
Outlook doesn't have a File Insert dalog Method (which is an annoyance to me). I know of two ways to accomplish it:
1. Pop the dialog by calling the built-in File Insert menu;
Dim cbtAttAdd As CommandBarButton
Set cbtAttAdd = ActiveInspector.CommandBars.FindControl(, 1079)
2. Use an API type call to get the target files to attach, such as the text attachment in <post#=643,183>post 643,183</post#> (which gets you 3/4ths of the way - you have to code the VBA Attachments.Add "pathfilename" commands with the files the code feeds).-John ... I float in liquid gardens