java.lang.NullPointerException

Discussion in 'Application Development' started by eforce, Aug 3, 2010.

  1. eforce

    eforce New Member
    5

    Aug 3, 2010
    2
    0
    5
    When I make an Android project in Eclipse following this tutorial:

    Android - Hello World

    I get: java.lang.NullPointerException

    When I try to open strings.xml under res/values/


    Is there any way to fix this?

    (Using Eclipse 3.6)


    Regards,

    eforce
     

    Advertisement
  2. Boogs

    Boogs Well-Known Member
    18

    Apr 6, 2010
    85
    16
    18
    I don't understand your problem fully.

    From the op, I understand that you try to click on strings.xml in Eclipse, and you somehow get a NullPointerException? Without actually running the program at all?

    Or, is it that you run your program, try to access a string contained within strings.xml, and then get a NullPointerException?
     
  3. boarderx

    boarderx New Member
    15

    Jul 1, 2010
    3
    0
    15
    I ran into this recently. This is a known bug in Eclipse and a workaround is coming (at least the post I read stated that). One way to get around the error for Android development is:

    Right-Click on the file
    Select Open With > Android XML Resources Editor

    It should open without the error.
     

Share This Page

Loading...