PC Review


Reply
Thread Tools Rate Thread

Browse to select a folder

 
 
Otto Moehrbach
Guest
Posts: n/a
 
      18th May 2010
Excel 2003-2007
An OP posted a problem and I realized that there was one thing I needed to
know before I could help him. What is the code to allow the user to select
a folder? The result must be the full path to that folder. Note: That
path will not be the path to ThisWorkbook. Thanks for your time. Otto

 
Reply With Quote
 
 
 
 
Ron de Bruin
Guest
Posts: n/a
 
      18th May 2010
See a example in the macro on this page
http://www.rondebruin.nl/csv.htm

'Browse to the folder with CSV files
Set oApp = CreateObject("Shell.Application")
Set oFolder = oApp.BrowseForFolder(0, "Select folder with CSV files", 512)
If Not oFolder Is Nothing Then
foldername = oFolder.Self.Path
If Right(foldername, 1) <> "\" Then
foldername = foldername & "\"
End If




--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm



"Otto Moehrbach" <(E-Mail Removed)> wrote in message news:(E-Mail Removed)...
> Excel 2003-2007
> An OP posted a problem and I realized that there was one thing I needed to
> know before I could help him. What is the code to allow the user to select
> a folder? The result must be the full path to that folder. Note: That
> path will not be the path to ThisWorkbook. Thanks for your time. Otto
>

 
Reply With Quote
 
Chip Pearson
Guest
Posts: n/a
 
      18th May 2010
I have code and a downloadable module at
http://www.cpearson.com/excel/BrowseFolder.aspx that displays the
standard Windows Browse Folder dialog.

Cordially,
Chip Pearson
Microsoft Most Valuable Professional,
Excel, 1998 - 2010
Pearson Software Consulting, LLC
www.cpearson.com



On Tue, 18 May 2010 13:10:27 -0400, "Otto Moehrbach"
<(E-Mail Removed)> wrote:

>Excel 2003-2007
>An OP posted a problem and I realized that there was one thing I needed to
>know before I could help him. What is the code to allow the user to select
>a folder? The result must be the full path to that folder. Note: That
>path will not be the path to ThisWorkbook. Thanks for your time. Otto

 
Reply With Quote
 
Otto Moehrbach
Guest
Posts: n/a
 
      18th May 2010
Thanks guys. Otto

"Chip Pearson" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I have code and a downloadable module at
> http://www.cpearson.com/excel/BrowseFolder.aspx that displays the
> standard Windows Browse Folder dialog.
>
> Cordially,
> Chip Pearson
> Microsoft Most Valuable Professional,
> Excel, 1998 - 2010
> Pearson Software Consulting, LLC
> www.cpearson.com
>
>
>
> On Tue, 18 May 2010 13:10:27 -0400, "Otto Moehrbach"
> <(E-Mail Removed)> wrote:
>
>>Excel 2003-2007
>>An OP posted a problem and I realized that there was one thing I needed to
>>know before I could help him. What is the code to allow the user to
>>select
>>a folder? The result must be the full path to that folder. Note: That
>>path will not be the path to ThisWorkbook. Thanks for your time. Otto


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Browse and select mail messages? Fox via OfficeKB.com Microsoft Outlook VBA Programming 1 22nd Jun 2006 05:50 AM
Any way to browse and select a directory on the web server in ASP.NET? Eric Microsoft ASP .NET 1 14th Feb 2005 07:34 PM
Browse Folder ( Folder Options ) won't change after new selection marca Windows XP Security 0 14th Jul 2004 05:50 AM
Browse Folder dialog with option to make New Folder Bradley C. Hammerstrom Microsoft Access Getting Started 2 6th Jan 2004 07:33 AM
Import File with browse and select (even from Pocket PC?) Brett9 Microsoft Excel Programming 3 4th Nov 2003 08:36 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 01:10 PM.