Need help on VBA code..

yameixtz

New Member
Joined
Oct 3, 2021
Messages
8
Office Version
  1. 2013
Platform
  1. Windows
Hi there. I was wondering if you could help me on this. I'm not good on Macros.

I wanted to group the data from SHEET2 by OFFICES (Column E) so I will be able to sum up their ACTUAL LITERS WITHDRAWN (Column K) per office. Once total liters is summed up by office.. I will be able to deduct the number of liters actually withdrawn of a certain office from SHEET2 to that summary in SHEET1 under LITERS WITHDRAWN (Column D). Then automatically it will deduct from (Column C) ALLOCATED LITERS and output on (Column E) under BALANCE LITERS.

I attached my test excel file for you to get a glimpse on.

It would mean a lot if you could help me on this guys. Hope to hear from you soon. Thank you. Keep safe everyone. :)
 

Attachments

  • sheet1.png
    sheet1.png
    113.9 KB · Views: 9
  • sheet2.png
    sheet2.png
    152.9 KB · Views: 8
I edit your file, you can see it.
Also you should change all 23 at your formula to last row of your source data at Sheet2.
 
Upvote 0

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).
I edit your file, you can see it.
Also you should change all 23 at your formula to last row of your source data at Sheet2.
why do the office CTO got 30 LITERS WITHDRAWN in Sheet1 when it has inly 20 ACTUAL LITERS WITHDRAWN from Sheet2?
 
Upvote 0
I forgot to fix second part of formula, check again file.
 
Upvote 0

Forum statistics

Threads
1,214,835
Messages
6,121,880
Members
449,057
Latest member
Moo4247

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