Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create a folder from excel
Hi all, i know it is possible to creat a shortcut on the desktop from
excel and would like to know if it is possible to create a folder from excel as well ? If so, could you help me some code please. thanks in advance, Tempy *** Sent via Developersdex http://www.developersdex.com *** |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create a folder from excel
Make a folder
MkDir "C:\Mytest\mine" you will need to create every level if they don't exsit. Shortcut '---------------------------------------------------------------- Sub CreateShortCut() '---------------------------------------------------------------- Dim oWSH As Object Dim oShortcut As Object Dim sPathDeskTop As String Set oWSH = CreateObject("WScript.Shell") sPathDeskTop = oWSH.SpecialFolders("Desktop") Set oShortcut = oWSH.CreateShortCut(sPathDeskTop & "\" & _ ActiveWorkbook.Name & ".lnk") With oShortcut .TargetPath = ActiveWorkbook.FullName .Save End With Set oWSH = Nothing End Sub -- HTH Bob Phillips "Tempy" wrote in message ... Hi all, i know it is possible to creat a shortcut on the desktop from excel and would like to know if it is possible to create a folder from excel as well ? If so, could you help me some code please. thanks in advance, Tempy *** Sent via Developersdex http://www.developersdex.com *** |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create a folder from excel
Tempy,
MkDir NickHK "Tempy" wrote in message ... Hi all, i know it is possible to creat a shortcut on the desktop from excel and would like to know if it is possible to create a folder from excel as well ? If so, could you help me some code please. thanks in advance, Tempy *** Sent via Developersdex http://www.developersdex.com *** |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create a folder from excel
Thanks so much Bob, how's the weather there ?
Tempy *** Sent via Developersdex http://www.developersdex.com *** |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create a folder from excel
Not too bad, autumn coming in now though.
-- HTH Bob Phillips "Tempy" wrote in message ... Thanks so much Bob, how's the weather there ? Tempy *** Sent via Developersdex http://www.developersdex.com *** |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create a folder from excel
Hi Bob, sorry for the delay, here it is really nice hot sunny days,
today 32 !! Bob, is it possible to assign a specific icon to the shortcut that you create ? Tempy *** Sent via Developersdex http://www.developersdex.com *** |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create a folder from excel
Yeah, just use the .IconLocation property when creating the shortcut.
-- HTH Bob Phillips "Tempy" wrote in message ... Hi Bob, sorry for the delay, here it is really nice hot sunny days, today 32 !! Bob, is it possible to assign a specific icon to the shortcut that you create ? Tempy *** Sent via Developersdex http://www.developersdex.com *** |
#8
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create a folder from excel
Hi Bob, thanks. I am not sure where to put it. Let me explain what i am
wanting to do.... should of done that before i guess. I want to send all the users an excel file with the code in and when they open it, it will create the folders and save the file in there. I then create a short cut and then want to assign a different icon to it. I am not sure how to do that portion, should i insert the icon on the spread sheet so that it can save it also to the folder ? Tempy *** Sent via Developersdex http://www.developersdex.com *** |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
how do you create file folder labels in excel? | New Users to Excel | |||
How to create the hyperlink from Excel doc. to the folder | Excel Discussion (Misc queries) | |||
How do I Create backup of excel file in other folder | Excel Discussion (Misc queries) | |||
Create Folder and Text File in folder | Excel Programming | |||
Create Folder / Copy Folder / Replace | Excel Programming |