![]() |
Can the user "Choose" the path via a VBA command?
I wish to work in a directory chosen by a user.
At the moment, I canąt seem to get it to recognise the folder where the user chooses a file with the łApplication.GetOpenFilename˛ command. I thought that this would be the easiest way, in that the user could choose a file in the folder they wanted to work in and Iąd change it somehow * not so. Any ideas ? |
Can the user "Choose" the path via a VBA command?
Cannot see what your problem is. The following returns the full path
on my PC (XL97/Windows NT4) f = Application.GetOpenFilename MsgBox (f) Regards BrianB ================================================== ======== Brad Patterson wrote in message ... I wish to work in a directory chosen by a user. At the moment, I canąt seem to get it to recognise the folder where the user chooses a file with the łApplication.GetOpenFilename˛ command. I thought that this would be the easiest way, in that the user could choose a file in the folder they wanted to work in and Iąd change it somehow * not so. Any ideas ? -- |
Can the user "Choose" the path via a VBA command?
Can the user "Choose" the path via a VBA command?You can put up the
directory selection dialog: http://j-walk.com/ss/excel/tips/tip29.htm How to select a directory found at John Walkenbach's site. -- Regards, Tom Ogilvy "Brad Patterson" wrote in message ... I wish to work in a directory chosen by a user. At the moment, I can't seem to get it to recognise the folder where the user chooses a file with the "Application.GetOpenFilename" command. I thought that this would be the easiest way, in that the user could choose a file in the folder they wanted to work in and I'd change it somehow - not so. Any ideas ? |
Can the user "Choose" the path via a VBA command?
Brad Patterson wrote:
I wish to work in a directory chosen by a user. At the moment, I can’t seem to get it to recognise the folder where the user chooses a file with the “Application.GetOpenFilename” command. I thought that this would be the easiest way, in that the user could choose a file in the folder they wanted to work in and I’d change it somehow – not so. Any ideas ? Look at the CHDIR command this will allow you change to the desired directory prior to using GetOpenFileName command. |
All times are GMT +1. The time now is 05:11 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com