Select folder with browser...

  • Thread starter Thread starter Juan Sanchez
  • Start date Start date
J

Juan Sanchez

Hi all,

I'm completelly new to programing macros for outlook, I
know my way arroung VBA mostly for XL.

However I have managed to create a custom button that will
save all the attachments on a message to my hard drive on
a specific folder. when running the macro I present the
user with an input box so that s/he can change the folder,
however this is not robust since the user could misstype
or call for an unexistent folder...

What I ultimatelly want is to have the user select either
the default folder or get a folder name from a browser
dialog box, just like the one that appears when you save
an attachment manually...

Is this possible?, can someone directme to where I can
find the method?...Am I making any sence?

Cheers
Juan
 
You can use the Windows common dialog controls set for that (comdlg32.ocx),
using the CommonDialog control. There is information about that control in
the MSDN library. Or you could instantiate an instance of Excel or Word in
your code, not show the application but use (for Excel) the
Application.GetSaveAsFilename method. That displays the standard SaveAs
dialog and you can customize it using some of its arguments. See the Object
Browser Help on that method to get you started.
 
Ken thanks for the input... I found a sample code for the
folder browser on the KN and is working fine, how ever I'm
still studying it, I don't like to use things I dont
understand...:), I'll check on your suggestions and see if
I can make something out of them...

Thankyou very much...

Juan
 
Hi,

can you tell me where i can find this example. Or can you post your code?

Thanks a lot.

Patt
 
Back
Top