Loop Through Multiple Worksheets With Different Formats and Grab Data From VBA R C
Hello VBA Community,
I have recently expanded from mostly working with imbedded formulas in Excel to working on learning more on the capability of VBA. I am struggling with transitioning from sheet imbedded to VBA content with relative references. On top of that, I am working on a project that will run through around 100 worksheets that have 2 different formats so I will need to distinguish which format to choose based on an in worksheet identifier.
So far I have an independent macro that combines all data worksheets into one workbook, then in "copycell()", copy formulas to all sheets for the data, then pull values only from each one of those sheets and combine it into one master sheet, then delete all of the rows that have zeros in column "AM".
As many of you are guessing, the runtime for this is slow and when I am able to include the case for the other sheet type, which I am not sure how to do, it will likely slow down more. Would anyone give me some guidance on how to make this faster as well as imbedding it into VBA rather than cell formulas? I would think the relative references would need variables and a counter because some inputs will apply to multiple lines while others are unique each line, but repeat further down the list.
I have included my workbook for you to check out what I have. On the Formulas tab you will see the formulas that I am using starting at "AJ7." I really appreciate any help you are willing to give me as well as I can provide more information if needed. This is my first post but I have already learned a lot from this forum by reading other's posts and am looking forward to learning more.