hi i'm new to programming, i'm trying to check whats the highest rev number in a folder (file names are 123456_rev01.*, 123456_rev02.*).
here is my code
For j = 1 To File.Exists("c:\test\123456" & "*" & j & ".*") = False
MsgBox("looking at rev" & j)
j = j + 1
Next
MsgBox("last heighest rev is" & j)
when i run it it just goes through the loop once even though I have the following files in that folder;
123456_rev01.dwf
123456_rev02.pdf
123456_rev03.pdf
All i want is the number 3 (highest rev).
here is my code
For j = 1 To File.Exists("c:\test\123456" & "*" & j & ".*") = False
MsgBox("looking at rev" & j)
j = j + 1
Next
MsgBox("last heighest rev is" & j)
when i run it it just goes through the loop once even though I have the following files in that folder;
123456_rev01.dwf
123456_rev02.pdf
123456_rev03.pdf
All i want is the number 3 (highest rev).