Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Use VBA to count the number of regions, i.e., the number of rows for the sales data. Note, your code should work if the size

image text in transcribed

Use VBA to count the number of regions, i.e., the number of rows for the sales data. Note, your code should work if the size of the data changes, so assign this number to a variable and use the variable whenever you need to refer to the size of the data. b. Use VBA (instead of name manager to create a worksheet-level range name "Sales" for the sales data. c. (4)Calculate the average of the sales using the name in step b and print the average to cell C1. d. Use VBA to delete the range name "Sales". e. Starting from cell C3 to cell C#, where # is the last row of sales data, calculate the "moving average" of 3 consecutive cells from column A using FormulaRic1 property of the cells. For example, the formula in cell C3 should calculate the average of cells A1 to A3, and the formula in cell C4 should calculate the average of cells A2 to A4, and so on. f. Use For Next loop to loop through all moving averages from C3 to C# to check if the moving average in each cell is greater than the average in C1 calculated in step c. If so, change the background color of the cell to yellow

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Introductory Relational Database Design For Business With Microsoft Access

Authors: Jonathan Eckstein, Bonnie R. Schultz

1st Edition

1119329418, 978-1119329411

More Books

Students also viewed these Databases questions