Auto move Selection

chaboyski

Board Regular
Joined
Aug 18, 2020
Messages
57
Office Version
  1. 2016
Platform
  1. Windows
Hi Team,

just wanted to check if there is a formula or a macro code that i can use if i wanted to automatically move the cell selection depending on the date.

sample below:

cell A1 includes validation and this would determine upto what date would be selected
cells C1 to G1 would be hard coded data
Cells i2 - m2 would have the formula that would be moving, example is if it may 8 on A1 is selected, the data from cells i2 - m2 would only select and calculate upto b2 to b9.

Book1
ABCDEFGHIJKLM
19-Maydata1data2data3data4data5Sum data1Sum data2Sum data3Sum data4Sum data5
21-May12312312312312311071107110711071107
32-May123123123123123
43-May123123123123123
54-May123123123123123
65-May123123123123123
76-May123123123123123
87-May123123123123123
98-May123123123123123
109-May123123123123123
1110-May
1211-May
1312-May
1413-May
1514-May
1615-May
Sheet1
Cell Formulas
RangeFormula
I2:M2I2=SUM(C2:C10)
Cells with Data Validation
CellAllowCriteria
A1List=$B$2:$B$16


Thank you in advanced.
 

Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.
Book1
ABCDEFGHIJKLM
18-Maydata1data2data3data4data5Sum data1Sum data2Sum data3Sum data4Sum data5
21-May123123123123123984984984984984
32-May123123123123123
43-May123123123123123
54-May123123123123123
65-May123123123123123
76-May123123123123123
87-May123123123123123
98-May123123123123123
109-May123123123123123
1110-May
1211-May
1312-May
1413-May
1514-May
1615-May
Sheet1
Cell Formulas
RangeFormula
I2:M2I2=SUMIF($B$2:$B$16,"<="&$A$1,C2:C16)
Cells with Data Validation
CellAllowCriteria
A1List=$B$2:$B$16
 
Upvote 1
Solution
Thank you @kevin9999

what if the Data in A1 is in another sheet? tried it but it gave me an error. but i just moved the date to the same sheet so it would work. thank you!
 
Upvote 0

Forum statistics

Threads
1,215,084
Messages
6,123,021
Members
449,092
Latest member
ikke

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