Match winning numbers with group and place them separately by group

motilulla

Well-known Member
Joined
Feb 13, 2008
Messages
2,422
Office Version
  1. 2010
Using Excel 2010

Hello,

1-In the Column C, in the cells C27:C56 I got 30 winning numbers which are from 0 to 36 could be many repeated times.

2-In the Column F, in the cells F2:F23 I have group1 of 21 numbers in the ascending order

3- In the Column G, in the cells G2:G23 I have group2 of 16 numbers in the ascending order

I need VBA which can scan winning numbers of column C, from cells C27:C56 and match with group1 and group2 and then place them separately according to group match Group1 in the column F, cells F27 to down and Group2 in the column G27 to down as shown below in the example attached sheet

Seperate Match As Per Group.xlsx
ABCDEFGHI
1
2Group 1Group 2
320
451
563
674
7811
8913
91014
101215
111619
121720
131826
142130
152231
162332
172435
182536
1927
2028
2129
2233
2334
24
25Total NumWinningTotal NumMatched In
26Total NumNumbersTotal NumGroup 1Group 2
27127127
28234234
293434
30425425
31524524
326060
33718718
348282
35912912
3610231023
3711271127
38127127
3913101310
40148148
4115251525
42163163
4317281728
44182182
4519201920
46204204
47213213
4822202220
4923102310
50247247
5125232523
5226322632
5327332733
54281281
5529282928
5630313031
57
58
Sheet1


Please help

Thank you all.

Regards,
Moti
 

Excel Facts

Format cells as date
Select range and press Ctrl+Shift+3 to format cells as date. (Shift 3 is the # sign which sort of looks like a small calendar).
Using Excel 2010
Hello,

Regards,
Moti
Using Excel 2010

Hello again,

Mainly I need to check winning numbers are in the cells C27:C56 with the Group1 & Group2 and the matching number put in to cells F27:G27 to down as per group column.

Say for example….
Cell C27 winning number is number=27 matches with Group1 & group2 as is have match with group1 place that number in group1 in cell F27

Cell C28 winning number is number=34 matches with Group1 & group2 as is have match with group2 place that number in group2 in cell G28

And continue match all 30 numbers as shown in the layout of post#1

Please help

Thank you all.

Regards,
Moti
 
Upvote 0
Hello again,

May someone have another idea to solve this task I will appreciate your input please help

Regards,
Moti
 
Upvote 0
Hello again,

I have broken my head but could not find another way to match out winning with each group I appropriate expert idea if it could be solved :)

Regards,
Moti
Using Excel 2010

Hello,

I did not get VBA but reading many posts of MrExcel I got a formula which has solved my query I am placing here the answer may help others I want to thank you all who have read this question and given a time and tried to solve this query.

Seperate Match As Per Group.xlsx
ABCDEFGHI
1
2Group 1Group 2
320
451
563
674
7811
8913
91014
101215
111619
121720
131826
142130
152231
162332
172435
182536
1927
2028
2129
2233
2334
24
25Total NumWinningTotal NumMatched In
26Total NumNumbersTotal NumGroup 1Group 2
27127127 
28234234 
29343 4
30425425 
31524524 
32606 0
33718718 
348282 
35912912 
3610231023 
3711271127 
38127127 
3913101310 
40148148 
4115251525 
4216316 3
4317281728 
44182182 
45192019 20
4620420 4
4721321 3
48222022 20
4923102310 
50247247 
5125232523 
52263226 32
5327332733 
5428128 1
5529282928 
56303130 31
57
58
Sheet1
Cell Formulas
RangeFormula
F27:F56F27=IF(ISERROR(INDEX($F$3:$F$23,MATCH(C27,$F$3:$F$23,FALSE),1)),"",INDEX($F$3:$F$23,MATCH(C27,$F$3:$F$23,FALSE),1))
G27:G56G27=IF(ISERROR(INDEX($G$3:$G$23,MATCH(C27,$G$3:$G$23,FALSE),1)),"",INDEX($G$3:$G$23,MATCH(C27,$G$3:$G$23,FALSE),1))


Kind Regards,
Moti
 
Upvote 0
Solution

Forum statistics

Threads
1,223,909
Messages
6,175,315
Members
452,634
Latest member
cpostell

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top