PC Review


Reply
Thread Tools Rate Thread

Code to Create Input Box To Select a File

 
 
Jeremy
Guest
Posts: n/a
 
      8th Apr 2008
I am looking to crate an input box that will allow the user to select a file.
This will be like the browes option. The file selected will not need to be
opened, just have the full path entered in the cell. This will be used to
formualte a VLOOKUP form the selected closed file.
 
Reply With Quote
 
 
 
 
Rick Rothstein \(MVP - VB\)
Guest
Posts: n/a
 
      8th Apr 2008
You could use code similar to this...

Dim FileName As String
FileName = Application.GetOpenFilename
Range("A1").Value = FileName

but you should look up the GetOpenFilename method in the help files as there
are some optional arguments available that will let you customize things a
little bit.

Rick


"Jeremy" <jeremiah.a.reynolds @ gmail.com> wrote in message
news:47CECA0A-D81B-44DA-B92D-(E-Mail Removed)...
>I am looking to crate an input box that will allow the user to select a
>file.
> This will be like the browes option. The file selected will not need to
> be
> opened, just have the full path entered in the cell. This will be used to
> formualte a VLOOKUP form the selected closed file.


 
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
Create listbox with code but can't select any items in list box OssieMac Microsoft Excel Programming 6 12th Jan 2010 09:26 PM
How to create an Input Mask (and necessary code) for an IP Address rich Microsoft Access Forms 2 24th Jan 2009 01:40 AM
How to create a Canadian Input Mask for the Post Code? =?Utf-8?B?R3Jk?= Microsoft Access Getting Started 5 25th Jan 2006 10:12 PM
Copy cells into another workbook with an input box to select the file scottdepauw Microsoft Excel Programming 0 19th Nov 2004 07:25 PM
CODE to select range based on User Input or Value of Input Field Sandi Gauthier Microsoft Excel Programming 4 8th Dec 2003 03:22 PM


Features
 

Advertising
 

Newsgroups
 


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