Auto populate individual cells based off cell values from data table with NO VBA

Stomli

New Member
Joined
Jun 22, 2023
Messages
8
Office Version
  1. 365
Platform
  1. Windows
Hi Forum,

This is my first time posting. I am usually able to find my answer to other questions by looking through the forums but I haven't been able to find an answer for this issue I'm having. So I am reaching out to the experts on here. Please and Thank you!

I need to auto populate dates for specific users based on cell values inside a table. I would like to implement them with dynamic array formulas so this can scale and update based on new reports. Also, I can't do this with macros or VBA since the end users can't work with them.

First thing I would need to know is how I would go about is how to make duplicate cells based on values (numbers) in a cell. I have been looking up some nested If functions, but I am not sure how they could work for a multiple month table with blanks in them.

The other thing I need is a method on how to tie these duplicate cells to a unique user I.d. while omitting blank fields for months without changes. I was thinking after the duplication if figured out that a sequence formula could just drag the duplicated dates down and use a filter() formula to match them to the right division.

I could develop the back end in a helper column/tab. If this is too difficult for one direct solution, please suggest methods or formulas that I could use to solve this.
1687471676655.png

Thanks for your time.

S
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
I don't understand your 2nd request. How about this for the first?

062023 Misc.xlsm
BCDEFGHIJKLMN
2DivJanFebMarAprMayJunJulAugSepOctNovDec
3A020010100400
4B000300020000
DateChg
Cell Formulas
RangeFormula
C3:N4C3=SUM((--($B$8:$B$20=$B3))*(--MONTH($D$8:$D$20)=COLUMN()-2))
 
Upvote 0
kweaver, I think the portion you gave formulas for is being hard coded in. I think Stomli wants to generate the table below with the table above. I've already tried and reverted to PowerQuery to at least get something that works.

But I'm sure they want a formula do generate at least the date column, but probably the division column as well. Haven't been able to get a formula to work yet.
 
Upvote 0
Thanks for your explanation Irobbo314. Yes, that is what I want for the dates column the division is a xlookup that already links the IDs So I don't need any help on that column but I need to get the dates to follow downward from the top of the user id. So I need 2 Feb dates for the 1st 2 users then a May date for the next user. I would need to input these 1 after the other taking into account the months that don't have any dates in them and also the division for each user Id.
 
Upvote 0
Also sorry for the screenshot. My company has my excel locked down so I can't get the add-in.
 
Upvote 0
With several helpers, this does it, I think...but it's a little more effort than really desired.
I haven't figured out a LET function for it or another shorter way.

This might temporarily get you over a hump if there's not too much to handle.

062023 Misc.xlsm
BCDEFGHIJKLMN
1123456789101112
2DivJanFebMarAprMayJunJulAugSepOctNovDec
3A020010100400
4B000300020000
5
6
7DivUserDateAB
8A2/1/202422123414
9A2/1/202415322844
10A5/1/2024174564
11A7/1/2024410578
12A10/1/20249108
13A10/1/202410
14A10/1/202410
15A10/1/202410
16B4/1/2024
17B4/1/2024
18B4/1/2024
19B8/1/2024
20B8/1/2024
DateChg
Cell Formulas
RangeFormula
C1:N1C1=SEQUENCE(,12)
D8:D15D8=DATE(2024,I8#,1)
F8:F11F8=TRANSPOSE(FILTER(C3:N3,C3:N3<>0))
G8:G11G8=TRANSPOSE(FILTER(C1#,$C$3:$N$3<>0))
I8:I15I8=XLOOKUP(SEQUENCE(SUM(F8#)),H8:H12,G8:G12,,-1)
J8:J9J8=TRANSPOSE(FILTER(C4:N4,C4:N4<>0))
K8:K9K8=TRANSPOSE(FILTER(C1#,$C$4:$N$4<>0))
M8:M12M8=XLOOKUP(SEQUENCE(SUM(J8#)),L8:L10,K8:K10,,-1)
L8,H8L8=1
L9:L10,H9:H12L9=L8+J8
D16:D20D16=DATE(2024,M8#,1)
Dynamic array formulas.
 
Upvote 0
Hello @Stomli .

Welcome to the MrExcel forum. Please accept my warmest greetings and sincere hope that all is well.


Try the following formulas.

In cell B8:
Excel Formula:
=MID(CONCAT(REPT(B3:B4,MAP(C3:N4,LAMBDA(m,m)))),SEQUENCE(SUM(C3:N4)),1)
1687535813504.png


In cell D8:
Excel Formula:
=LET(a,C3:N4,--MID(CONCAT(REPT(C2:N2,MAP(a,LAMBDA(m,m)))),5*(SEQUENCE(SUM(a))-1)+1,5))
1687535826892.png


I attached the images so you can see the result.


--------------
Let me know the result and I'll get back to you as soon as I can.
Cordially
Dante Amor
--------------​
 
Last edited:
Upvote 1
Hi @Stomli

I updated the formulas and images:

In cell B8:
Excel Formula:
=MID(CONCAT(REPT(B3:B4,MAP(C3:N4,LAMBDA(m,m)))),SEQUENCE(SUM(C3:N4)),1)

Or like this, so you only have to change a range of cells.
Excel Formula:
=LET(a,C3:N4,MID(CONCAT(REPT(B3:B4,MAP(a,LAMBDA(m,m)))),SEQUENCE(SUM(a)),1))


1687536281214.png



In cell D8:

Excel Formula:
=LET(a,C3:N4,--MID(CONCAT(REPT(C2:N2,MAP(a,LAMBDA(m,m)))),5*(SEQUENCE(SUM(a))-1)+1,5))

1687536388937.png




--------------
Let me know the result and I'll get back to you as soon as I can.
Cordially
Dante Amor
--------------​
 
Last edited:
Upvote 0
Hi Kweaver:
Dante, why isn't "m" defined somewhere?
'm' in Lambda takes the matrix of the function where it is embedded, in this case Map(a is the function and matrix 'a' is the matrix 'm' inside Lambda.

Excel Formula:
MAP(a,LAMBDA(m,m))
 
Upvote 0

Forum statistics

Threads
1,224,820
Messages
6,181,154
Members
453,021
Latest member
Justyna P

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