Automate loop in a loop problem

Alternate

New Member
Joined
Feb 21, 2019
Messages
1
Hello there,

I am trying to automate a filter for lottery backtest programme.
I made the VB macro work but with a lot of buttons But it's dragging me behind because I cannot be able to backtest quickly.
I need a loop to automate the process.
I don't know how to loop it


THIS IS WHAT I DO MANUALLY ALL THE TIME.

(backtest ROW link 21 Y143: Y148. below the LEMON GREEN arrow)

# after I execute BUTTON 1, the first matched number is 12 from first row "F53" from E48:E53, F48:F53...
# I manually SUBTRACT 12 from 52
# answer is 40
# CLICK GO DOWN TO SELECT BUTTON
# LOOK 40 on Colum E148: BD148
# 40 is on BB148
# 12 is on the second row so I will have to paste row BA143:BA148. so it can match up.
# click copy and paste button 49 below the RED arrow which will copy and paste it
# then I click the BUTTON 2 which will compare and give the result.

full files available via the link below

https://gator4234.hostgator.com:208...rop=&charset=&file_charset=&baseurl=&basedir=

ACTION AND RESULT
#continue from BUTTON 1
#To be able to loop through E48:E53, F48:F53, G48:G53, HF48:H53, I48:I53 TO BD48:BD53 in that order
# select the first number /Value
#subtract the number from 52 and look for the result on the corresponding columns from E143:BD143,E144:BD144,E145:BD145,E146:BD146,E147:BD147or E148:BD148
#make E48:E53 AS ROW 0 from the first number matched.


Best Regards
Easy Ajibola
 

Excel Facts

Wildcard in VLOOKUP
Use =VLOOKUP("Apple*" to find apple, Apple, or applesauce

Forum statistics

Threads
1,214,832
Messages
6,121,853
Members
449,051
Latest member
excelquestion515

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