I'm trying to compare two columns in different worksheets and when I hit a match, move other data columns in the matching row back to the other sheet.
First problem: I can't seem to see any "value" in the code window when I mouse over it. I'm guessing there is a problem with having both sheets active at the same time? Any suggestions would be greatly appreciated.
I'm running Windows 8.1 and Excel 2013 (Office 365 version) on a Core i5 machine with 32GB of memory.
I'm not sure how to post or attach a copy of the sheets I'm using... everything I've tried doesn't seem to work (PrtScr, Snipping Tool, JPG, attachments), so if you'd like to see it, please let me know how to go about that as well.
The code I've written is below (marked with * doesn't seem to work - .Value doesn't show anything when moused over):
Worksheets(Array("Standings", "Data")).Select
Do Until PlayerNum > 24
Select Case StandingsRow
Case 0, 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 33
PlayerA = True
Case Else
PlayerA = False
End Select
* If Worksheets("Data").Range("AG1").Offset(PlayerNum, 0).Value = _
* Worksheets("Standings").Range("B5").Offset(StandingsRow, 0).Value Then
* NameMatch = True
* Else
* StandingsRow = StandingsRow + 1
* End If
If NameMatch Then
* Worksheets("Standings").Range("c5").Offset(StandingsRow, 0).Value = _
* Worksheets("Data").Range("z1").Offset(PlayerNum, 0)
* Worksheets("Standings").Range("g5").Offset(StandingsRow, 0).Value = _
* Worksheets("Data").Range("aa1").Offset(PlayerNum, 0)
If PlayerA Then
* Worksheets("Standings").Range("h5").Offset(StandingsRow, 0).Value = _
* Worksheets("Data").Range("ae1").Offset(PlayerNum, 0)
End If
NameMatch = False
StandingsRow = 0
PlayerNum = PlayerNum + 1
Else
StandingsRow = StandingsRow + 1
End If
Loop
Hopefully, this makes some sort of sense. If not, let me know and I'll try to explain further.
Thanks very much in advance,
Vinny
First problem: I can't seem to see any "value" in the code window when I mouse over it. I'm guessing there is a problem with having both sheets active at the same time? Any suggestions would be greatly appreciated.
I'm running Windows 8.1 and Excel 2013 (Office 365 version) on a Core i5 machine with 32GB of memory.
I'm not sure how to post or attach a copy of the sheets I'm using... everything I've tried doesn't seem to work (PrtScr, Snipping Tool, JPG, attachments), so if you'd like to see it, please let me know how to go about that as well.
The code I've written is below (marked with * doesn't seem to work - .Value doesn't show anything when moused over):
Worksheets(Array("Standings", "Data")).Select
Do Until PlayerNum > 24
Select Case StandingsRow
Case 0, 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 33
PlayerA = True
Case Else
PlayerA = False
End Select
* If Worksheets("Data").Range("AG1").Offset(PlayerNum, 0).Value = _
* Worksheets("Standings").Range("B5").Offset(StandingsRow, 0).Value Then
* NameMatch = True
* Else
* StandingsRow = StandingsRow + 1
* End If
If NameMatch Then
* Worksheets("Standings").Range("c5").Offset(StandingsRow, 0).Value = _
* Worksheets("Data").Range("z1").Offset(PlayerNum, 0)
* Worksheets("Standings").Range("g5").Offset(StandingsRow, 0).Value = _
* Worksheets("Data").Range("aa1").Offset(PlayerNum, 0)
If PlayerA Then
* Worksheets("Standings").Range("h5").Offset(StandingsRow, 0).Value = _
* Worksheets("Data").Range("ae1").Offset(PlayerNum, 0)
End If
NameMatch = False
StandingsRow = 0
PlayerNum = PlayerNum + 1
Else
StandingsRow = StandingsRow + 1
End If
Loop
Hopefully, this makes some sort of sense. If not, let me know and I'll try to explain further.
Thanks very much in advance,
Vinny