views:

371

answers:

1

Is there a tool, method or setting in VBA to warn about variables that have been DIMmed, but aren't being used?

+9  A: 

MZ-Tools will search through your code and tell you what is not being used. The version for VBA can be found here.

The specific feature in MZ-Tools that performs what you asking about is Review Source Code:

The Review Source Code feature allows you to review the source code to detect some unused declarations (constants, variables, parameters, procedures, etc.).

Jon Fournier
A great add-in, and free for VBA
Matt Dillard
That worked great, the perfect tool for the job.
Lance Roberts
Yes: It is free, easy, and very efficient. Once you notice how much you save time by using it, please do like me: donate!
Philippe Grondier