mehidy1437
Active Member
- Joined
- Nov 15, 2019
- Messages
- 348
- Office Version
- 365
- 2016
- 2013
- Platform
- Windows
- Mobile
- Web
Hello dear,
I have data in a2:f5, a1:f1 is header row.
a2:c5 contain the details like style, order & color
d2:f5 contain the quantity. I would like to perform the calculation on d2:f5.
d2:f5 each cell will divided by 30, like 100/30=3.333
so for d2 it will be 100/30=3.3333, in d2 cell value will be 30 & i will put 3 in g2
balance value 100-(30*3) = 10, will put on d3 & i will put 1 in g3 for this.
like this it will go on for others cell.
I want to do this using variant array, i want to load the data a2:f5 in array > do the calculation & then insert the output in the sheet.
See below raw data, & required output.
Please help me to do this.
Raw data
Desired output
I have data in a2:f5, a1:f1 is header row.
a2:c5 contain the details like style, order & color
d2:f5 contain the quantity. I would like to perform the calculation on d2:f5.
d2:f5 each cell will divided by 30, like 100/30=3.333
so for d2 it will be 100/30=3.3333, in d2 cell value will be 30 & i will put 3 in g2
balance value 100-(30*3) = 10, will put on d3 & i will put 1 in g3 for this.
like this it will go on for others cell.
I want to do this using variant array, i want to load the data a2:f5 in array > do the calculation & then insert the output in the sheet.
See below raw data, & required output.
Please help me to do this.
Raw data
pkl v04.xlsm | ||||||||
---|---|---|---|---|---|---|---|---|
A | B | C | D | E | F | |||
1 | STYLE | ORDER | COLOR | S | M | L | ||
2 | XXX | 200 | 300 | 100 | 100 | 90 | ||
3 | XXX | 200 | 400 | 100 | 60 | 100 | ||
4 | XXX | 300 | 300 | 100 | 100 | 120 | ||
5 | YYY | 300 | 400 | 100 | 140 | 100 | ||
Sheet1 (30) |
Desired output
pkl v04.xlsm | |||||||||
---|---|---|---|---|---|---|---|---|---|
A | B | C | D | E | F | G | |||
1 | STYLE | ORDER | COLOR | S | M | L | CTN | ||
2 | XXX | 200 | 300 | 30 | 3 | ||||
3 | XXX | 200 | 300 | 10 | 1 | ||||
4 | XXX | 200 | 300 | 30 | 3 | ||||
5 | XXX | 200 | 300 | 10 | 1 | ||||
6 | XXX | 200 | 300 | 30 | 3 | ||||
7 | XXX | 200 | 400 | 30 | 3 | ||||
8 | XXX | 200 | 400 | 10 | 1 | ||||
9 | XXX | 200 | 400 | 30 | 2 | ||||
10 | XXX | 200 | 400 | 30 | 3 | ||||
11 | XXX | 200 | 400 | 10 | 1 | ||||
12 | XXX | 300 | 300 | 30 | 3 | ||||
13 | XXX | 300 | 300 | 10 | 1 | ||||
14 | XXX | 300 | 300 | 30 | 3 | ||||
15 | XXX | 300 | 300 | 10 | 1 | ||||
16 | XXX | 300 | 300 | 30 | 4 | ||||
17 | YYY | 300 | 400 | 30 | 3 | ||||
18 | YYY | 300 | 400 | 10 | 1 | ||||
19 | YYY | 300 | 400 | 30 | 4 | ||||
20 | YYY | 300 | 400 | 20 | 1 | ||||
21 | YYY | 300 | 400 | 30 | 3 | ||||
22 | YYY | 300 | 400 | 10 | 1 | ||||
Sheet1 (34) |