Load part of data to memory, perform some calculations and rank then show alert with message box -vba

kelly mort

Well-known Member
Joined
Apr 10, 2017
Messages
2,169
Office Version
  1. 2016
Platform
  1. Windows
This is the formula I am using to get data to second sheet.

Code:
Sheet2.Range("D7:M" & lr) = "=Sheet1!I7+Sheet1!S7*0.2"

Sheet1
SHEET_1.jpg


Sheet2
Screenshot_2020-02-17-00-20-36-1-1.png


Now what I want to do is to be able to load the portion of data from sheet2 for say category "X" into memory. Now I don't want to interact with the worksheet anymore. So looking at the formula as a guide, I want to perform those calculations in memory. Then I find the totals each row , D:M into N .

All in memory, if only that's possible.

If all the above go well, then what I want next is to be able to rank the total for ID 408 against the items in column N Sheet2 then display outcome with message box.

I wish and hope some can pull it up for me.

Thanks
 

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.
Hi again and again @DanteAmor,

I said I was going to take a break but could not take it yet.

I want to find the average of all the non zero processed data as explained below :

So from the first column of the data stored to the 10th column, we find the average of all of them. This time, no categories involved. So say our rows are 500, then we find the average of all the 500 by 10 data range (that are greater than zero) and place the result in TextBox1


Then we also find the average for the column 11, the non zero data and place result in TextBox2
 
Upvote 0
I also had this problem,
Thanks for sharing
--------------------
apkafe!
 

Attachments

  • 1583315769579.png
    1583315769579.png
    312 bytes · Views: 11
Upvote 0
Hi again and again @DanteAmor,

I said I was going to take a break but could not take it yet.

I want to find the average of all the non zero processed data as explained below :

So from the first column of the data stored to the 10th column, we find the average of all of them. This time, no categories involved. So say our rows are 500, then we find the average of all the 500 by 10 data range (that are greater than zero) and place the result in TextBox1


Then we also find the average for the column 11, the non zero data and place result in TextBox2

@DanteAmor,

Please is what I am asking for possible?

Please let me know.

Thanks
 
Upvote 0

Forum statistics

Threads
1,223,911
Messages
6,175,325
Members
452,635
Latest member
laura12345

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