I am enetering results of a competition in an Excel spreadsheet. There are 50 competitors who are listed in a matrix. The result is given to me in the form of Competitor 02 W Competitor 47 L on date 18/09/09.
I use the following code to enter the data via pop up boxes..
Sub EnterResult()
Cells.Replace What:=InputBox("ENTER 1ST PAIR OF BOWLERS eg 0247"), Replacement:=InputBox("ENTER FIRST BOWLER'S RESULT AND DATE eg W1108"), LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False
Cells.Replace What:=InputBox("ENTER PAIR OF BOWLERS IN REVERSE eg 4702"), Replacement:=InputBox("ENTER FIRST BOWLER'S RESULT AND DATE eg L1108"), LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False
End Sub
The matrix consists of 'co-ordinates' at the intersections already filled in.
So what the code does is finds the string 0247 in the matrix and replaces it with W 18/09, then finds the string 4702 in the matrix and replaces it with L 18/09. What I would like is that once I have done the first bit ie entered the result for 0247 as W 18/09 to have the second result ie for 4702 ....L 18/09, entered automatically without any further input from myself.
This is perhaps a very 'dirty' way of performing these actions but with my limited knowledge of code was the best solution I was able to come up with.
So any help with my suggested requirement or tackling the problem in a completely different way would be very much appreciated.
Regards
Smalty
I use the following code to enter the data via pop up boxes..
Sub EnterResult()
Cells.Replace What:=InputBox("ENTER 1ST PAIR OF BOWLERS eg 0247"), Replacement:=InputBox("ENTER FIRST BOWLER'S RESULT AND DATE eg W1108"), LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False
Cells.Replace What:=InputBox("ENTER PAIR OF BOWLERS IN REVERSE eg 4702"), Replacement:=InputBox("ENTER FIRST BOWLER'S RESULT AND DATE eg L1108"), LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False
End Sub
The matrix consists of 'co-ordinates' at the intersections already filled in.
So what the code does is finds the string 0247 in the matrix and replaces it with W 18/09, then finds the string 4702 in the matrix and replaces it with L 18/09. What I would like is that once I have done the first bit ie entered the result for 0247 as W 18/09 to have the second result ie for 4702 ....L 18/09, entered automatically without any further input from myself.
This is perhaps a very 'dirty' way of performing these actions but with my limited knowledge of code was the best solution I was able to come up with.
So any help with my suggested requirement or tackling the problem in a completely different way would be very much appreciated.
Regards
Smalty