Sum value corresponding to cells containing duplicate text

Joined
Apr 1, 2011
Messages
8
I have a command button that copies construction materials from a data entry worksheet to a summary worksheet. I need to add to the command button a code that will allow me to sum the values associated with materials that may have been entered multiple times by the user on the data entry worksheet The problem is the text relating to the material is across columns A to D and I need the quantity and the materials carbon emissions summed together .

Any Help will be appreciated thank you, I am a relatively inexperienced user of VBA.

James
 
Last edited:

Excel Facts

How can you automate Excel?
Press Alt+F11 from Windows Excel to open the Visual Basic for Applications (VBA) editor.
So the description of the material is in columns A to D, the quantity is in column E and the carbon emissions in F
so if a particular material turns up more than once I need the quantity and carbon emissions of all the entries for that material to be added together and displayed as one entry
 
Upvote 0

Forum statistics

Threads
1,224,574
Messages
6,179,626
Members
452,933
Latest member
patv

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