Calling Class Initialize 2+ times

Roger Garstang

Well-Known Member
Licensed User
Longtime User
When you call Initialize a 2nd time, is it supposed to create a new class or after the first time is it just then considered a method/sub? I've been going through trying to convert a Code Module for creating custom EditTexts to a class and expected a new class I guess, but don't appear to be getting it. I initialize the view in the Initialize of the class too, but it just appears to be working with the same view/class. When I type in the first it also types in the 2nd like they are cloned.
 

Roger Garstang

Well-Known Member
Licensed User
Longtime User
Ok, that helped me make my mind up about how to code it then. I was thinking of an array of views to make navigating/"tab order" of them easier, but I make double use of Initialize and actually have it return the view created with the view's tag equal to the class (using me when it is created in the class) and was thinking a new class was created each time so couldn't use an array. This will actually make it easier now as long as it stays that way. I can now have one class with arrays/lists of everything and make the tag of the view somehow hold an index...this should be interesting when done and will actually use less memory than I was thinking since each view won't need to store its own class.
 
Top