(11-08-2024, 06:39 AM)vince Wrote: global variables are reserved for either inexperienced, lazy, or really advanced programmers -- stick to the middle of the pack for the safer betGlobal variables work for me, but I make sure to name them in such a way that identifies them as global - ie g_MyVar or m_MyVar (in VBA, the m is for module, as in variables common to the current module).
But any routines I expect to be truly portable can't rely on global variables, their values are passed via parameters.