Find the column by name and to sum that column

GirishDhruva

Active Member
Joined
Mar 26, 2019
Messages
308
Hi everyone i am posting for 1st time in MrExcel, Help me to solve this.
Here is the table.
AppleBallCatDogElephant
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366
12343234324544366

<colgroup><col><col><col span="3"></colgroup><tbody>
</tbody>
From the above table i need to find "Ball" and sum that column and that should be shown in a particular cell in VBA
 
I don't understand that question either I'm afraid. You've calculated the sum in that code so you can do whatever you like with it.
 
Upvote 0

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
Sorry , to be clear in my question that i found the solution for my problem but i need that answer in negative and that sum should be copied to another sheet, i am not getting how to do that , can u suggest me any way to solve it.
 
Upvote 0
You already worked out the answer using Application.Sum(fnd) so you can just assign that anywhere and negate it - e.g.

Code:
Sheets("some sheet").Range("A1").value = -application.sum(fnd)
 
Last edited:
Upvote 0
Ya i have already found but my pointer will not be pointing to the solution that i have found , so my pointer should point to that solution , can u assist me for that .
But the solution that you have given will be pointing to "A1" , i need my pointer to point at my solution (example my pointer would be pointing "A1", but the solution that i have found would be in "A27",so how can i point to that, this is just an example. please don't reply as "Sheets("some sheet").Range("A27").value = -application.sum(fnd)")
 
Last edited:
Upvote 0

Forum statistics

Threads
1,215,781
Messages
6,126,868
Members
449,345
Latest member
CharlieDP

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