Hi welu1805,
consider that Basic is not Pascal. If you're used to Wirth's rule of declaring (in that order) labels, constants, types, variables, procedures and functions even Delphi doesn't strictly adhere to it.
In B4A, dimming a variable is like declaring it. So dimming it twice is sort of re-declaring it where first instance is left to the garbage collector to be collected for eventual working memory reuse.
udg