I was searching around and looking for a macro that will when run it will convert the files in the location into .stp files and I came across the below. how can i manipulate it to grab the next file in the folder and continue the next files and convert them until all the files have been converted.
Dim swApp As Object
Dim Part As Object
Dim FilePath As String
Dim sFilePath As String
Dim PathSize As Long
Dim PathNoExtention As String
Dim NewFilePath As String
Dim FileLocation As String
Dim sPath As String
Dim i As Long
Dim bRebuild As Boolean
Dim bRet As Boolean
Dim sRev As String
Dim nErrors As Long
Dim nWarnings As Long
Sub main()
Set swApp = Application.SldWorks
Set Part = swApp.ActiveDoc
FilePath = Part.GetPathName
PathSize = Strings.Len(FilePath)
sPath = Left(Part.GetPathName, InStrRev(Part.GetPathName, "\"))
sRev = Part.CustomInfo("re") 'Change Configuration Property name here
FileLocation = "C:"
PathNoExtension = Strings.Left(FilePath, PathSize - 7)
Part.SaveAs (PathNoExtension & "rev" & sRev & ".step")
End Sub