i want to loop through a column (item) then depend on value of cells create a folders with name of specific cell for example if find x = 20 then create folder "20_hhh" we have alot of 20 but i want just a folder if find 30 then create then create folder 30 _hhh and so on !
each time x (value of cell ) increase 10 time
this is an example of column
Item
10
10
10
10
20
20
30
30
40
40
40
i have a code , but it doesnt work, anybody can help me?
Sub create_loop()
Dim BrowseForFolder As String
Dim fName5 As String
Dim fName3 As String
Dim fName1 As String
Dim fName4 As String
Dim x As String
With Worksheets("Output_" & Date).Range("B1:B100")
x = 20
fName5 = .Range("D3").Value
fName3 = "PO_"
fName1 = "000"
fName4 = "_"
BrowseForFolder = "X:\fei"
Set c = .Find(x, LookIn:=xlValues)
If Not c Is Nothing Then
firstAddress = c.Address
Do
MkDir "my specific folder"
x = 10 + x
Set c = .FindNext(c)
Loop While Not c Is Nothing And c.Address <> firstAddress
End If
End With
End Sub