|
-
Mar 29th, 2023, 04:56 PM
#13
Re: A really, really strange Excel problem
 Originally Posted by jdc2000
Zvoni,
Thanks. Now I understand what is happening. I retested it on my computers, and it does not matter what you set strCol to, "AJ" or "XX", it shows as "" in the ToolTip if you put the break point on that line. If you put the break point on the End Sub, it works OK. You cannot put a break point on the commented out MsgBox, but you can if it is not commented. I usually avoid this issue by inserting Stop statements into the code where I want to check something.
Funny enough, in VBA i use a lot of „old school“ variable checking issuing Debug.Print‘s
i take it out of production code with a global const.
something along the lines
Code:
Public Const DO_DEBUG As Boolean = True
‘Somewhere else
If DO_DEBUG Then Debug.Print SomeVariable
When the code goes live i just set the constant to False
Last edited by Zvoni; Tomorrow at 31:69 PM.
----------------------------------------------------------------------------------------
One System to rule them all, One Code to find them,
One IDE to bring them all, and to the Framework bind them,
in the Land of Redmond, where the Windows lie
---------------------------------------------------------------------------------
People call me crazy because i'm jumping out of perfectly fine airplanes.
---------------------------------------------------------------------------------
Code is like a joke: If you have to explain it, it's bad
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|