Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create folders on a shared drive with a macro
I would like a macro that would create a folder on one of our shared
drives and would name this folder based on what is in one of the cells in the current worksheet. Does anyone have a clue how to do this? Any help is appreciated. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create folders on a shared drive with a macro
Hi Michael
Sub test() Dim x As String x = "R:\MyExistingFolder\" & Range("A1") On Error Resume Next MkDir x End Sub -- XL2002 Regards William "Michael McClellan" wrote in message om... | I would like a macro that would create a folder on one of our shared | drives and would name this folder based on what is in one of the cells | in the current worksheet. Does anyone have a clue how to do this? | Any help is appreciated. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create folders on a shared drive with a macro
Michael,
This creates a folder on the D drive. Dim oFSO As Object Dim oFolder As Object Set oFSO = CreateObject("Scripting.FileSystemObject") Set oFolder = oFSO.CreateFolder("D:\" & ActiveSheet.Range("A1")) Haven't tested on a shared drive, but as long as you have access, and the drive is mapped, it should work. -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "Michael McClellan" wrote in message om... I would like a macro that would create a folder on one of our shared drives and would name this folder based on what is in one of the cells in the current worksheet. Does anyone have a clue how to do this? Any help is appreciated. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Create folders from list vb/macro? | Excel Discussion (Misc queries) | |||
Saving shared spreadsheets on a shared drive. | Excel Discussion (Misc queries) | |||
shared spreadsheet on a shared drive | Excel Discussion (Misc queries) | |||
Printing viewing a shared workbook on a shared drive | Excel Discussion (Misc queries) | |||
Drive - Folders - Files | Excel Discussion (Misc queries) |