Hello,
I need to create macro for creating folders with the name from excel cells.
I have VBS script, but it is not working.
Sub CreateFolders()
'Get the active worksheet
Dim ws As Worksheet
Set ws = ActiveSheet
'Get the range of cells with the folder names
Dim rng As Range
Set rng = ws.Range("A1:A10")
'Loop through the range of cells
For Each cell In rng
'Create a new folder with the name of the cell
MkDir "D:\Users\F86702D\Desktop\G048\MASS FOLDER" & cell.Value
Next cell
End Sub
I would be very thankful for some help
I need to create macro for creating folders with the name from excel cells.
I have VBS script, but it is not working.
Sub CreateFolders()
'Get the active worksheet
Dim ws As Worksheet
Set ws = ActiveSheet
'Get the range of cells with the folder names
Dim rng As Range
Set rng = ws.Range("A1:A10")
'Loop through the range of cells
For Each cell In rng
'Create a new folder with the name of the cell
MkDir "D:\Users\F86702D\Desktop\G048\MASS FOLDER" & cell.Value
Next cell
End Sub
I would be very thankful for some help