Forum Discussion
New VBA person - Code not working
Thanks so much for your reply. Unfortunately, the requirement from above was to use VBA (long story). I tried using "Record Macro" and using the formulat to try and get it into VBA but then I went down the "rabbit" hole because, again, from above, the requirement was to add "extras". In any case, again, thank you for the follow up. . . and just in case the question is: "why don't you explain it to the folks "above", tried that and it was easier for me to start learning VBA (I guess something good always comes from "bad"). Best wishes, KC
- mathetesMay 29, 2025Gold Contributor
Got it. I still might push back a bit, especially if you can make a formula (or set of formulas, perhaps coupled with a Pivot Table) that works.
Short story to illustrate: back when I was employed (I retired over 20 years ago), I was for a time the Director of the HR and compensation database for a major corporation. One of our responsibilities was to produce a monthly headcount report--by division, how many people in each employment category (Full time, part time, temp, etc)--and how have numbers changed since prior month. The company's IT experts could only conceive of doing this by means of a major VBA routine that took data extracted from the DB2 database and massaged it to produce the results. It took a solid 30 minutes to run. I used built-in Excel (at the time it may have been Lotus 1-2-3) formulas and functions to yield the same result almost instantaneously.
Lesson: there's a mis-apprehension that "big jobs" require VBA, an apprehension that may sometimes be accurate, but often fails to appreciate the power that has already been "programmed" into the functions themselves.