goldenvision
Board Regular
- Joined
- Jan 13, 2004
- Messages
- 234
Any ideas what is wrong with the following code
I think it is reading through a table of data and each time the Marque equals the Marque selected in a combo box it copies the value to a new sheet, increases the row count by one and carries on. Evidently that isn't happening.
Any pointers would be greatly appreciated.
Code:
Private Sub createMarqueRange()
'specify start sheet
Sheets("Cleaned Sewells (Full File)").Activate
'specify start points
cMRc = 3
currRow = 2
'when to stop
Do Until Cells(currRow, 1) = "x"
If Cells(currRow, 12).Value = cbo_Marques Then
Sheets("Cleaned Sewells (Full File").Range("B" & cMRc, "Q" & cMRc, "S" & cMRc, "T" & cMRc).Copy Sheets("Lookups").Range("C" & currRow)
currRow = currRow + 1
Sheets("Cleaned Sewells (Full File)").Select
Else
'do nothing
End If
cMRc = cMRc + 1
Application.StatusBar = cMRc
Loop
Application.StatusBar = False
End Sub
I think it is reading through a table of data and each time the Marque equals the Marque selected in a combo box it copies the value to a new sheet, increases the row count by one and carries on. Evidently that isn't happening.
Any pointers would be greatly appreciated.