First of a Few Roadblocks...

Copper Contributor

I am building a commissions Workbook in Excel 365 for my sales team. Each of the 12 months is its own worksheet, and then I have a database worksheet used to compile all the raw data from each month's worksheets, which then feeds into a Totals worksheet that is neatly formatted (all within the same workbook). Within each of the month's, there is a section for new contracts. The range of that section is E58:K67, headers not included. Though there are 10 empty rows for the salespeople to enter their new contract data, not all 10 rows will always be utilized every month (sadly). I am trying to compile the data from that range from each of the months into my database worksheet so that all the new contracts the salesperson has sold YTD is neatly displayed on the totals worksheet AND have sortable columns if they want to sort the data differently (Sold Date, Customer, Description, Contract Type, Contract Amount are the 5 row headers). I am looking for a VBA code that will compile only the utilized rows from each month's worksheet and then another VBA code to have sortable columns on the Totals worksheet. I imagine the solution will require viewing the workbook, but if you know of some references, videos, or articles you think pertain to what I am trying to accomplish, I would be very grateful. I have spent quite a bit of time searching for code and the solutions I have found online just aren't right. Thank you, in advance.

1 Reply

@GrantSpitler Difficult to visualise what exactly you have designed, but in general, it is not a good idea to gather data in twelve separate sheets and then try to combine these into one master sheet for analysis. Better to collect raw data in one large table for all months and all sales people. No empty rows or columns. No separate sections for new and recurring contracts. Just a sequential list of sales orders with some extra columns that identify the type (recurring/new) and the data. And preferably in a structured Excel table.

 

Then use Excel's built-in tools to filter, summarise the data by person, customer, contract type, time period. Whatever! These tools could be pivot tables (regular or Power), Power Query, or some of the fairly new and very powerful functions that are available in Excel for MS365 and E2021.