Application.FileSearch in Outlook

milesUK

Active Member
Joined
Jan 5, 2003
Messages
388
In MS Outlook 2000 I have created a VBA macro (partially gleaned from the net) to create a new Outlook mail item and attach Excel files before sending. All works fine so far but I now need to change it to identify ALL of the files in a single folder and attach them to the mail item.

I have used
Code:
Dim fsoFileSearch As FileSearch
Set fsoFileSearch = Application.FileSearch
but this errors (@ the .FileSearch line) with Object does not support this property or method. As does
Code:
Dim outApp As Application 'As Outlook.Application
Set outApp = New Outlook.Application
With outApp.FileSearch
I know that this is closer to File-->Open than Insert-->File but can anyone shed any light on this isssue please. All that I require is a means, within Outlook 2000, of getting the filenames of files within a folder. I would prefer to leave this as an Outlook macro as it is being created for someone else to use who does not (edited!) normally use Excel.[/i]
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.

Forum statistics

Threads
1,225,360
Messages
6,184,505
Members
453,236
Latest member
Siams

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top