Android Question IsInitialized with custom types not accurate?

Creideiki

Active Member
Licensed User
Longtime User
Hi all,

I'm a bit confused. I have Activities like this:
Main:
Sub Process_Globals
    Type testType (a as String, b as Int)
End Sub
...
Activity1:
Sub Process_Globals
    dim tt as testType
End Sub

Sub Activity_Create(FirstTime as Boolean)
    tt.Initialize
End Sub
...

When I log tt.IsInitialized here, it is true as expected.

Now I have a class which uses Activity1.tt. That works, I can access the correct values, but Activity1.tt.IsInitialized gives me 'false'. It is definitly called after Activity1 is created (I ensured my with logging anything).

I tried to create a simple app which could show this behaviour, but there it works.

* Has anyone an idea what could happen here?
* Is there anything that coud go wrong if I didn't test if tt is initialized (I only use simple types in that custom type)?
 

Creideiki

Active Member
Licensed User
Longtime User
Well, I know, Erel...
but for a project with a dozen of activities and many other classes it would imply a complete rewrite. And my customer wouldn't pay for that.
 
Upvote 0
Top