Another compelling argument for using procedures: Readability!
Writing procedures for code reuse is a fairly common concept. Recently, while reading Clean Code by Robert C. Martin, I became aware of a different reason to use procedure in you VBA code.
By structuring code into procedures, you can significantly improve the intuitive readability of your code. Watch the video to see how some complex, technical if-blocks read almost like plain English after I encapsulated them into their own functions.
I’m still amazed how effective this very simple approach is. All the more, as I have more than ten years of experience in programming and never had that idea myself.
Book recommendation:
Clean Code: A Handbook of Agile Software Craftsmanship - Robert C. Martin
[ Ссылка ] (Amazon Affiliate Link)
More info on the Better VBA video series: [ Ссылка ]
If you like this video, please share, like, and subscribe to this channel!
Ещё видео!