473,326 Members | 2,023 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

Open Folder Dialog and put full selected folder path in textbox

Hi guys,

I want a command button which when presed opens the Folder dialog box and when a folder has been selected the full path appears in a text box.... I can't for the life of me fathom out how to do it.... Help please?
Feb 25 '14 #1
3 4644
MikeTheBike
639 Expert 512MB
Hi

You can use something like this
Expand|Select|Wrap|Line Numbers
  1.     With Application.FileDialog(msoFileDialogFolderPicker)
  2.         .AllowMultiSelect = False
  3.         .Title = "Dialogue Caption/Title"
  4.  
  5.         If .Show = -1 Then
  6.             'Assign folder returned to text box here
  7.             MsgBox .SelectedItems.Item(1)
  8.         End If
  9.     End With
You can find more info on Application.FileDialog in Access help.

HTH
Feb 25 '14 #2
perfect. muchly appreciated :)
Feb 25 '14 #3
zmbd
5,501 Expert Mod 4TB
For more information you should read thru the following insight article:
Select a File or Folder using the FileDialog Object
Feb 25 '14 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Venkat | last post by:
Hi, I have an file1.exe file stored at some physical location say C:\Test\file1.exe. I created a virtual folder say MyFolder pointing to my physical folder(C:\Test\). I wrote this piece of...
5
by: Phil Stanton | last post by:
Can anyone let me have the code for opening the open file dialog box and getting either a file or folder name as the output. I suspect it will look like Function GetPathOrFile(InputPath as...
9
by: Amit D.Shinde | last post by:
How to enable user for selecting only folders and not the files with the Open File Dialog. i.e. I want only path of the selected folder is to be returned by Open File Dialog. i.e Open File Dialog...
3
by: Zyrthofar | last post by:
Hello I am searching for a way, in Windows Explorer, to add an entry in the context menu when you right-click a folder. What I want to do is copy the path to the clipboard. I know how to set...
0
by: Me | last post by:
I have an application that has a text box. At the end on the text box is the standard elypsis (command button) for launching the Open File Dialog box. I want the user to select a certain executable...
6
by: Allen | last post by:
Hi, I want to retrieve the selected folder and entered file name from the SaveFilsDialog. The user is able to create or selected a different folder during the dialog displayed. If user enters...
0
by: madhu | last post by:
Hi all I have a problem in this code which deletes all the prvious folders. If you have any idea please give it. Thanks in advance. Madhukar Arvind Kumar void CHtmlGeneratorDlg::OnAdd() {...
3
by: spamsink42 | last post by:
hello how do i create a dialog to allow the user to choose a folder? i tried FolderBrowserDialog but encountered a couple of problems: - when you specify the starting location (property...
2
by: abdulbasith | last post by:
open file dialog needs compulsary any file to be selected, but i need to open only the folders, once i open the folder i need to retrieve the directory path alone. can any one help me in this.. ...
7
by: rayken15 | last post by:
I'm working to add a simple GUI form to an already existing perl script. The script simply takes a part number and an output path. It then connects to a client application and downloads data to the...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.