Solved

Change count to Sum

Posted on 2011-02-25
4
264 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
Comment Utility
Try:

worksheetfunction.Sum(rngYesterday)
0
 
LVL 18

Expert Comment

by:WarCrimes
Comment Utility
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
Comment Utility
Perfect, thats done the trick.

Thanks Patrick
0
 
LVL 45

Expert Comment

by:patrickab
Comment Utility
Seamus2626 - Thanks for thegrade - Patrick
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

This tutorial explains how to create a series of drop-down lists that are dependent upon prior selections to guide (“force”) the user to make the correct selection and reduce data errors within Microsoft Excel. Excel 2010 was used for this tutorial;…
Workbook link problems after copying tabs to a new workbook? David Miller (dlmille) Intro Have you either copied sheets to a new workbook, and after having saved and opened that workbook, you find that there are links back to the original sou…
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 how to create Excel charts: column, area, line, bar, and scatter charts. Formatting tips are provided as well.

763 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now