If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
|
#1
|
|||
|
|||
How to open OS window from a form
Access 2000, Win XP
I have a form with a Listbox control which shows a list of files in a particular folder on the Server PC (via a network). I want to be able to click a button on the form and open a window on the same folder so that I can move, copy, delete, etc the files in the folder. The full pathname to the selected folder is stored in a Text box on the form. In other words, I want the button to simulate the operation of :- minimizing the Access window, navigating to the folder on the Server PC and opening a window on the same folder (which is what I have to do at the moment if I want to change anything in the folder). To return to the database I can just click on the Access button on the Task Bar. What code would I need to do this (if it's even possible). TIA Peter Hibbs. |
#2
|
|||
|
|||
How to open OS window from a form
This may help:
http://www.mvps.org/access/api/api0002.htm -- Arvin Meyer, MCP, MVP http://www.datastrat.com http://www.mvps.org/access http://www.accessmvp.com "Peter Hibbs" wrote in message ... Access 2000, Win XP I have a form with a Listbox control which shows a list of files in a particular folder on the Server PC (via a network). I want to be able to click a button on the form and open a window on the same folder so that I can move, copy, delete, etc the files in the folder. The full pathname to the selected folder is stored in a Text box on the form. In other words, I want the button to simulate the operation of :- minimizing the Access window, navigating to the folder on the Server PC and opening a window on the same folder (which is what I have to do at the moment if I want to change anything in the folder). To return to the database I can just click on the Access button on the Task Bar. What code would I need to do this (if it's even possible). TIA Peter Hibbs. |
#3
|
|||
|
|||
How to open OS window from a form
Arvin,
No, not quite what I wanted, I already have the pathname for the required folder, what I want is to open a window on the folder as if I had opened the folder in Windows XP. Any other ideas? Peter Hibbs. On Fri, 9 May 2008 06:28:38 -0400, "Arvin Meyer [MVP]" wrote: This may help: http://www.mvps.org/access/api/api0002.htm |
#4
|
|||
|
|||
How to open OS window from a form
I'm still not sure what you want then. You can browse inside a folder with:
http://www.mvps.org/access/api/api0001.htm -- Arvin Meyer, MCP, MVP http://www.datastrat.com http://www.mvps.org/access http://www.accessmvp.com "Peter Hibbs" wrote in message ... Arvin, No, not quite what I wanted, I already have the pathname for the required folder, what I want is to open a window on the folder as if I had opened the folder in Windows XP. Any other ideas? Peter Hibbs. On Fri, 9 May 2008 06:28:38 -0400, "Arvin Meyer [MVP]" wrote: This may help: http://www.mvps.org/access/api/api0002.htm |
#5
|
|||
|
|||
How to open OS window from a form
"Arvin Meyer [MVP]" wrote in message ... I'm still not sure what you want then. You can browse inside a folder with: http://www.mvps.org/access/api/api0001.htm -- Arvin Meyer, MCP, MVP http://www.datastrat.com http://www.mvps.org/access http://www.accessmvp.com "Peter Hibbs" wrote in message ... Arvin, No, not quite what I wanted, I already have the pathname for the required folder, what I want is to open a window on the folder as if I had opened the folder in Windows XP. Any other ideas? Peter Hibbs. On Fri, 9 May 2008 06:28:38 -0400, "Arvin Meyer [MVP]" wrote: This may help: http://www.mvps.org/access/api/api0002.htm |
#6
|
|||
|
|||
How to open OS window from a form
Arvin,
OK, a bit more detail. Imagine you are sitting in front of the computer and Access is displaying a form on screen. One of the Text fields is displaying a pathname to a folder, say "C:\My Documents\Access\Accounts\" for example (actually it will normally be a path to a folder on a Server PC). Now I decide I want to delete one of the files in that folder so I minimize Access (or click on the Show Desktop icon on the task bar which does the same thing), I click the Windows Start button, then My Computer, then double click C:\, then double click the My Documents folder, then double click the Access folder, then double click the Accounts folder which then shows me the contents of the Accounts folder. Now I can delete the file (or whatever). With a Network system it would be even more long winded. OK, the user can set up short cuts to the 'root' folder to speedup the process a bit but there are hundreds of subsidiary folders involved here. The point is that I already know the pathname of the required folder (it's stored in a Text box on the form) so I would like a button on the same form which, when clicked, will, in effect perform all the actions shown above, and open a window on the required folder. I suppose another alternative (which may be acceptable to my client) is to run Windows Explorer using the Shell command. Not sure how to do that either as I would also need to pass the stored pathname to it somehow. Any ideas? Peter Hibbs. On Fri, 9 May 2008 19:17:32 -0400, "Arvin Meyer [MVP]" wrote: I'm still not sure what you want then. You can browse inside a folder with: http://www.mvps.org/access/api/api0001.htm |
#7
|
|||
|
|||
How to open OS window from a form
One last question. I understand that you know the path to the folder. Do you
know the filename as well? or will the user be required to just browse to find it? -- Arvin Meyer, MCP, MVP http://www.datastrat.com http://www.mvps.org/access http://www.accessmvp.com "Peter Hibbs" wrote in message ... Arvin, OK, a bit more detail. Imagine you are sitting in front of the computer and Access is displaying a form on screen. One of the Text fields is displaying a pathname to a folder, say "C:\My Documents\Access\Accounts\" for example (actually it will normally be a path to a folder on a Server PC). Now I decide I want to delete one of the files in that folder so I minimize Access (or click on the Show Desktop icon on the task bar which does the same thing), I click the Windows Start button, then My Computer, then double click C:\, then double click the My Documents folder, then double click the Access folder, then double click the Accounts folder which then shows me the contents of the Accounts folder. Now I can delete the file (or whatever). With a Network system it would be even more long winded. OK, the user can set up short cuts to the 'root' folder to speedup the process a bit but there are hundreds of subsidiary folders involved here. The point is that I already know the pathname of the required folder (it's stored in a Text box on the form) so I would like a button on the same form which, when clicked, will, in effect perform all the actions shown above, and open a window on the required folder. I suppose another alternative (which may be acceptable to my client) is to run Windows Explorer using the Shell command. Not sure how to do that either as I would also need to pass the stored pathname to it somehow. Any ideas? Peter Hibbs. On Fri, 9 May 2008 19:17:32 -0400, "Arvin Meyer [MVP]" wrote: I'm still not sure what you want then. You can browse inside a folder with: http://www.mvps.org/access/api/api0001.htm |
Thread Tools | |
Display Modes | |
|
|