Hi, this is my first post so please bear with me if I have not done it correctly!
The below code allows the user to browse for a file and then applies the relevant macro from modules depending on the file format. What I want to do is to enable selection of multiple workbooks and then have the macro applied to each in turn. Never tried doing this before so not sure how to go about it, any help would be appreciated.
'Showing Excel Open Dialog Form
vfile = Application.GetOpenFilename("Excel Files (*.csv*), *.csv", 1, "Select Excel File", "Open", False)
If TypeName(vfile) = "Boolean" Then 'If Cancel then exit
Exit Sub
End If
'Open the selected file
Workbooks.Open vfile, Local:=True
'Check to see if correct converter is being used
'1. Check to see if data is from CT24 tracker
Application.Goto Reference:="R1C2"
If ActiveCell.Value = 0 Then ' the CT24 file has all data in Column A
Call Module1.ct24
Application.ScreenUpdating = True
Unload UserForm1
Application.Goto Reference:="R1C1"
Exit Sub
End If
'2. Datong Rapids or GC-101
Application.Goto Reference:="R1C7"
z = ActiveCell.Value
If Mid(z, 1, 4) = "AUTO" Then
Call Module2.GC101
Application.ScreenUpdating = True
Unload UserForm1
Application.Goto Reference:="R1C1"
Exit Sub
Else
Call Module3.Datong
Application.ScreenUpdating = True
Unload UserForm1
Application.Goto Reference:="R1C1"
Exit Sub
End If
End Sub
Private Sub OptionSet1_Click()
End Sub
Private Sub UserForm_Click()
End Sub