Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / March 2005

Tip: Looking for answers? Try searching our database.

How to get/select one or more filenames

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Ebbe - 29 Mar 2005 19:07 GMT
Hey!

I have a Word-macro, that reads some data from one ore more .txt files.
The name of the files is given at each run.
I am looking for a dialog box, in the style of Dialogs(wdDialogFileOpen),
that returns me name and path of one or more selected files.
If it is possible to give a initial directory to search in and one or more
searchpatterns like "Textfiles (*.txt), *.txt" I would be delighted!

Running MS-Office 2000 and 2003

Ebbe
Cindy M  -WordMVP- - 29 Mar 2005 21:50 GMT
Hi Ebbe,

> I have a Word-macro, that reads some data from one ore more .txt files.
> The name of the files is given at each run.
[quoted text clipped - 4 lines]
>  
> Running MS-Office 2000 and 2003

2002 and 2003, yes, there's a handy-dandy FileDialog object. Prior to those
versions, however, there's no really good solution for selecting multiple
files that doesn't involve messing with the Windows API, or creating your
own lists in a UserForm. Or, perhaps using a TreeControl (something I've
never tried).

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :-)
Ebbe - 29 Mar 2005 22:15 GMT
Exactly what I looked for :-)

Do You (or other in this group) have the API code for earlier versions of
MS-Office?

Ebbe

"Cindy M -WordMVP-" <C.Meister-C@hispeed.ch> skrev i en meddelelse
news:VA.0000aa9e.00844eaa@speedy...
> Hi Ebbe,
>
[quoted text clipped - 22 lines]
> This reply is posted in the Newsgroup; please post any follow question or
> reply in the newsgroup and not by e-mail :-)

Rate this thread:






 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.