Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default How do I set up a form to select files from


In Excel VBA, I want to set up a small form for selecting a file from a
folder full of files. I tried using some VB code I had in another
project and it didn't work.

Any ideas or suggestions out there?

Thanks!!


--
greaseman
------------------------------------------------------------------------
greaseman's Profile: http://www.excelforum.com/member.php...o&userid=28808
View this thread: http://www.excelforum.com/showthread...hreadid=531671

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default How do I set up a form to select files from

Take a look at GetOpenFilename in VBA Help.

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"greaseman" wrote
in message ...

In Excel VBA, I want to set up a small form for selecting a file from a
folder full of files. I tried using some VB code I had in another
project and it didn't work.

Any ideas or suggestions out there?

Thanks!!


--
greaseman
------------------------------------------------------------------------
greaseman's Profile:

http://www.excelforum.com/member.php...o&userid=28808
View this thread: http://www.excelforum.com/showthread...hreadid=531671



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default How do I set up a form to select files from

Try code like the following:


Dim FName As Variant
FName = Application.GetOpenFilename("Excel files *.xls,*.xls", ,
"Select A File")
If FName = False Then
' no file selected
Else
MsgBox FName
End If


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"greaseman"
wrote in
message
...

In Excel VBA, I want to set up a small form for selecting a
file from a
folder full of files. I tried using some VB code I had in
another
project and it didn't work.

Any ideas or suggestions out there?

Thanks!!


--
greaseman
------------------------------------------------------------------------
greaseman's Profile:
http://www.excelforum.com/member.php...o&userid=28808
View this thread:
http://www.excelforum.com/showthread...hreadid=531671



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default How do I set up a form to select files from


And again,

thank you both for your assistance! I'll give your suggestions a try
in the morning, since it's about the end of my work day.

Have a great dat!


--
greaseman
------------------------------------------------------------------------
greaseman's Profile: http://www.excelforum.com/member.php...o&userid=28808
View this thread: http://www.excelforum.com/showthread...hreadid=531671

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do you get outlook to select from list on a form gbpg Excel Discussion (Misc queries) 1 August 27th 07 05:54 PM
Form Button - Select Row Paul Brown[_2_] Excel Programming 4 January 21st 06 01:44 PM
list related files, select which to open form Sami82[_5_] Excel Programming 0 September 14th 05 05:38 AM
Select all/Deselect all button in a form Stuart[_5_] Excel Programming 2 August 6th 03 07:55 PM
My First User Form - How to Select Range(s) and Print Bruce Roberson[_2_] Excel Programming 3 July 25th 03 03:09 AM


All times are GMT +1. The time now is 04:17 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"