K kohle Active Member Licensed User Longtime User Apr 23, 2015 #1 It should be get_Counter, but shows only _Counter
Erel B4X founder Staff member Licensed User Longtime User Apr 23, 2015 #2 The name you are using for the property is not valid as identifier names should not start with underscore. Usually the compiler will throw an error about this, however in this case it doesn't.
The name you are using for the property is not valid as identifier names should not start with underscore. Usually the compiler will throw an error about this, however in this case it doesn't.
K kohle Active Member Licensed User Longtime User Apr 23, 2015 #3 The name of the sub in the class is get_Counter() as string
Erel B4X founder Staff member Licensed User Longtime User Apr 23, 2015 #4 Yes, this creates a property named _Counter which is not an allowed identifier.
klaus Expert Licensed User Longtime User Apr 23, 2015 #5 You should use getCounter() As String in this case Counter is considered by the compiler as a property ! So you should return a value for Counter. You could also use setCounter to set the Counter property. If you want the routin being a subroutine you could use GetCounter or Get_Counter, in this case they will be considered as routines and not as Properties.
You should use getCounter() As String in this case Counter is considered by the compiler as a property ! So you should return a value for Counter. You could also use setCounter to set the Counter property. If you want the routin being a subroutine you could use GetCounter or Get_Counter, in this case they will be considered as routines and not as Properties.
K kohle Active Member Licensed User Longtime User Apr 23, 2015 #6 I understood. Please, put yourself in the position of a beginner. What happen in my case : 1) Definitly I use jk.get_Counter and it works without an error. 2) On the right site I see in the List (tab modules) get_Counter 3) I only dont see it correct in the combobox. For a beginner this is certainly not clear What can be or not the developer of b4a should control. (Warning .... and so on) rgs Kohle
I understood. Please, put yourself in the position of a beginner. What happen in my case : 1) Definitly I use jk.get_Counter and it works without an error. 2) On the right site I see in the List (tab modules) get_Counter 3) I only dont see it correct in the combobox. For a beginner this is certainly not clear What can be or not the developer of b4a should control. (Warning .... and so on) rgs Kohle