[AC-4012] Android - scrollableView java.lang.NullPointerException
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | n/a |
Status | Closed |
Resolution | Needs more info |
Resolution Date | 2016-07-16T08:54:31.000+0000 |
Affected Version/s | Appcelerator Studio 4.5.0 |
Fix Version/s | n/a |
Components | n/a |
Labels | scrollableView, titanium |
Reporter | Anna |
Assignee | Shak Hossain |
Created | 2016-07-07T10:51:25.000+0000 |
Updated | 2016-12-22T08:09:36.000+0000 |
Description
Hello,
I'm using a scrollableView on my app. On iOS all works perfect, but on Android always appear this error:
[ERROR] : TiApplication: (main) [11106,32386] Sending event: exception on thread: main msg:java.lang.NullPointerException; Titanium 5.4.0,2016/04/25 22:10,63d6351
[ERROR] : TiApplication: java.lang.NullPointerException
[ERROR] : TiApplication: at ti.modules.titanium.ui.widget.TiUIScrollableView$ViewPagerAdapter.instantiateItem(TiUIScrollableView.java:533)
[ERROR] : TiApplication: at android.support.v4.view.PagerAdapter.instantiateItem(PagerAdapter.java:110)
[ERROR] : TiApplication: at android.support.v4.view.ViewPager.addNewItem(ViewPager.java:870)
[ERROR] : TiApplication: at android.support.v4.view.ViewPager.populate(ViewPager.java:1020)
[ERROR] : TiApplication: at android.support.v4.view.ViewPager.setCurrentItemInternal(ViewPager.java:552)
[ERROR] : TiApplication: at android.support.v4.view.ViewPager.setCurrentItemInternal(ViewPager.java:514)
[ERROR] : TiApplication: at android.support.v4.view.ViewPager.dataSetChanged(ViewPager.java:946)
[ERROR] : TiApplication: at android.support.v4.view.ViewPager$PagerObserver.onChanged(ViewPager.java:2910)
[ERROR] : TiApplication: at android.database.DataSetObservable.notifyChanged(DataSetObservable.java:37)
[ERROR] : TiApplication: at android.support.v4.view.PagerAdapter.notifyDataSetChanged(PagerAdapter.java:276)
[ERROR] : TiApplication: at ti.modules.titanium.ui.widget.TiUIScrollableView.setViews(TiUIScrollableView.java:472)
[ERROR] : TiApplication: at ti.modules.titanium.ui.ScrollableViewProxy.handleMessage(ScrollableViewProxy.java:110)
[ERROR] : TiApplication: at android.os.Handler.dispatchMessage(Handler.java:98)
[ERROR] : TiApplication: at android.os.Looper.loop(Looper.java:146)
[ERROR] : TiApplication: at android.app.ActivityThread.main(ActivityThread.java:5511)
[ERROR] : TiApplication: at java.lang.reflect.Method.invokeNative(Native Method)
[ERROR] : TiApplication: at java.lang.reflect.Method.invoke(Method.java:515)
[ERROR] : TiApplication: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1283)
[ERROR] : TiApplication:
[ERROR] : TiApplication: at dalvik.system.NativeStart.main(Native Method)
This error appear when this line is executed:
$.lists.setViews(tables_sort);
I'm having this error now when I scroll Please any solution???
Hi, Thanks for reaching us. Do you have some test case to demonstrate what you are trying? We can offer you to look into your code and help to identify errors. Regards, Aminul
This is an error when closing a window in a ScrollableView.