NullPointerException at android. widget. AbsListView. obtainView at android. widget. ListView. makeAndAddView, androidlistview

Source: Internet
Author: User

NullPointerException at android. widget. AbsListView. obtainView at android. widget. ListView. makeAndAddView, androidlistview

 

When using ExpandableListView, the following error is returned. Online Search found that null was returned in the getGroupView () method of CommonNumberQueryAdapter. Pay attention to the details !!!

 

12-19 17:32:41. 822: E/AndroidRuntime (1894): fatal exception: main
12-19 17:32:41. 822: E/AndroidRuntime (1894): java. lang. NullPointerException
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. AbsListView. obtainView (AbsListView. java: 2269)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. ListView. makeAndAddView (ListView. java: 1769)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. ListView. fillDown (ListView. java: 672)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. ListView. fillSpecific (ListView. java: 1330)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. ListView. layoutChildren (ListView. java: 1600)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. AbsListView. onLayout (AbsListView. java: 2102)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. View. layout (View. java: 13754)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. ViewGroup. layout (ViewGroup. java: 4362)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. LinearLayout. setChildFrame (LinearLayout. java: 1649)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. LinearLayout. layoutVertical (LinearLayout. java: 1507)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. LinearLayout. onLayout (LinearLayout. java: 1420)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. View. layout (View. java: 13754)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. ViewGroup. layout (ViewGroup. java: 4362)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. FrameLayout. onLayout (FrameLayout. java: 448)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. View. layout (View. java: 13754)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. ViewGroup. layout (ViewGroup. java: 4362)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. LinearLayout. setChildFrame (LinearLayout. java: 1649)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. LinearLayout. layoutVertical (LinearLayout. java: 1507)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. LinearLayout. onLayout (LinearLayout. java: 1420)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. View. layout (View. java: 13754)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. ViewGroup. layout (ViewGroup. java: 4362)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. widget. FrameLayout. onLayout (FrameLayout. java: 448)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. View. layout (View. java: 13754)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. ViewGroup. layout (ViewGroup. java: 4362)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. ViewRootImpl. Adjust mlayout (ViewRootImpl. java: 1866)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. ViewRootImpl. extends mtraversals (ViewRootImpl. java: 1687)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. ViewRootImpl. doTraversal (ViewRootImpl. java: 998)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. ViewRootImpl $ TraversalRunnable. run (ViewRootImpl. java: 4212)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. Choreographer $ CallbackRecord. run (Choreographer. java: 725)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. Choreographer. doCallbacks (Choreographer. java: 555)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. Choreographer. doFrame (Choreographer. java: 525)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. view. Choreographer $ FrameDisplayEventReceiver. run (Choreographer. java: 711)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. OS. Handler. handleCallback (Handler. java: 615)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. OS. Handler. dispatchMessage (Handler. java: 92)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. OS. Looper. loop (Looper. java: 137)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at android. app. ActivityThread. main (ActivityThread. java: 4745)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at java. lang. reflect. Method. invokeNative (Native Method)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at java. lang. reflect. Method. invoke (Method. java: 511)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at com. android. internal. OS. ZygoteInit $ MethodAndArgsCaller. run (ZygoteInit. java: 786)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at com. android. internal. OS. ZygoteInit. main (ZygoteInit. java: 553)
12-19 17:32:41. 822: E/AndroidRuntime (1894): at dalvik. system. NativeStart. main (Native Method)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.