A Aysic4Bandroid Member Licensed User Longtime User May 15, 2012 #1 Hi, I was trying to use 'Types' and kept getting NullPointerExeptions and discovered the problem is that as well as initializing the 'type' you also have to initialize its members ... is this correct ?? i'm slightly confused as to the benefit of using them. Logically i thought initializing the type would treat its members as 'class' members of an Object. This thread member: http://www.b4x.com/forum/basic4android-updates-questions/16368-cannot-initialize-if-held-view.html#post93100 had the same issue but i'm still non the wise since the example in the documentation do not clarify anything.
Hi, I was trying to use 'Types' and kept getting NullPointerExeptions and discovered the problem is that as well as initializing the 'type' you also have to initialize its members ... is this correct ?? i'm slightly confused as to the benefit of using them. Logically i thought initializing the type would treat its members as 'class' members of an Object. This thread member: http://www.b4x.com/forum/basic4android-updates-questions/16368-cannot-initialize-if-held-view.html#post93100 had the same issue but i'm still non the wise since the example in the documentation do not clarify anything.
Erel B4X founder Staff member Licensed User Longtime User May 16, 2012 #2 You should not get a NullPointerExeption once you initialize the type. This doesn't mean that the members are initialized. It doesn't always make sense (and it is not possible) to initialize the members automatically. Upvote 0
You should not get a NullPointerExeption once you initialize the type. This doesn't mean that the members are initialized. It doesn't always make sense (and it is not possible) to initialize the members automatically.