Android Question Difference between DIM and Private?

Izmirov.Yaminovich

Member
Licensed User
Longtime User
Hi,

Just a question about what I can read on the forum. Are there any difference between dim and private? The guide that I downloaded are using private as for the rest of the forum tutorial uses dim. Are there any specific reason to use any of them?

Thanks
 
a private variable can only be accessed from the activity the var is defined in. Resp. it is only available in the sub the variable is declared in.
 
Upvote 1
To me it seems like 'dim' was used in the past and is still working. But now you should go with 'private'/'public'.
 
Upvote 0
The Guides use Private or Public, these are the advised keywords.
Dim remains only for compatibility.
Many users still use Dim, 'old habits'.
You may have a look at chapter 10.5 Scope in the B4A Beginner's Guide.
 
Upvote 0
Back
Top