Solved

Change count to Sum

Posted on 2011-02-25
4
268 Views
Last Modified: 2012-06-27
Hi i have the following lines of code that counts Columns+Rows.

Can i change this to sum?

rngYesterday.Columns.Count
rngYesterday.Rows.Coun

Thanks
Seamust
0
Comment
Question by:Seamus2626
  • 2
4 Comments
 
LVL 45

Accepted Solution

by:
patrickab earned 500 total points
ID: 34981899
Try:

worksheetfunction.Sum(rngYesterday)
0
 
LVL 18

Expert Comment

by:Cory Vandenberg
ID: 34982689
Can you elaborate what you are trying to sum?  The values in the columns and rows, by columns separately, by rows separately, or sum the # of Columns and # of Rows?

Your question is a little vague.
0
 

Author Closing Comment

by:Seamus2626
ID: 34995659
Perfect, thats done the trick.

Thanks Patrick
0
 
LVL 45

Expert Comment

by:patrickab
ID: 34995807
Seamus2626 - Thanks for thegrade - Patrick
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Improved? Move/Copy Add-in Replacement - How to avoid the annoying, “A formula or sheet you want to move or copy contains the name XXX, which already exists on the destination worksheet.” David Miller (dlmille)  It was one of those days… I wa…
This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
Graphs within dashboards are meant to be dynamic, representing data from a period of time that will change each time the dashboard is updated with new data. Rather than update each graph to point to a different set within a static set of data, t…
This Micro Tutorial demonstrates in Microsoft Excel how to consolidate your marketing data by creating an interactive charts using form controls. This creates cool drop-downs for viewers of your chart to choose from.

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question