I am a new employee taking over for someone who is already gone. I can program my own macros in VBA, but I'm not the best at understanding someone else's code and I'm not sure what approach to take.Especially since this code violates many programming best practices (contains lots of GOTOs, is inefficient, not well-organized). I don't even know what the code is doing as there's no documentation. My job is going to be to make this code better, maybe even rewrite it. But I can't rewrite it unless I understand what it's doing. The person who uses the spreadsheet and wants me to look it over says it takes 4 hours to run, so it's not really possible to use the debugger to step through.
So, should I make flow charts? Notes in the code? Is there a tool for annotating code to better understand it?
Any tips are appreciated. It looks like this is going to be my job for some time to come, and I will be looking over many spreadsheets like this and trying to make them maintainable and well-documented.
Bookmarks