Results 1 to 3 of 3
Like Tree1Likes
  • 1 Post By pbrockway2

Thread: Errod in R.id, cannot find symbol variable id.

  1. #1
    aparnakm is offline Member
    Join Date
    Feb 2012
    Posts
    1
    Rep Power
    0

    Default Errod in R.id, cannot find symbol variable id.

    In xml file i have written

    <LinearLayout>
    ..
    </LinearLayout>
    <EditText>
    android:id="@+id/txtusername"
    ....
    </EditText>

    In .java file i have written

    user = (EditText) findViewById(R.id.txtusername)

    i am getting error - cannot find symbol : variable id
    i am not getting error for R. After typing R, i am able to get
    class,attr,layout,string options. but i am not getting id.
    in R.java i have methods for all 3(attr,layout,string) but i dont have it for
    id.If i add it i'am getting message R.java is system generated cannot modify it.

  2. #2
    agater is offline Member
    Join Date
    Jul 2011
    Posts
    12
    Rep Power
    0

    Default Re: Errod in R.id, cannot find symbol variable id.

    I had the same error .

    to solve it you have to save the code >>

  3. #3
    pbrockway2 is offline Moderator
    Join Date
    Feb 2009
    Location
    New Zealand
    Posts
    4,565
    Rep Power
    12

    Default Re: Errod in R.id, cannot find symbol variable id.

    Cross posted at javaprogrammingforums.com

    @OP: It is a very good idea to let everybody know when you do this. Just politeness, really, as anybody contributing to the discussion you have started ought to have access the to the complete discussion.

    Also some people feel that contributing something to a question that may well have been answered elsewhere is a waste of time. If your multiple posts are discovered by accident - without you being upfront about it - (and they will be!), yet others won't respond out of annoyance.
    DarrylBurke likes this.

Similar Threads

  1. Cannot find symbol variable
    By xalebo in forum New To Java
    Replies: 4
    Last Post: 11-28-2011, 07:09 PM
  2. Java cannot find symbol- variable img
    By crutchfieldj in forum New To Java
    Replies: 3
    Last Post: 04-13-2010, 10:47 PM
  3. Cannot find symbol variable - Why? I can.. ^^
    By Mattedatten in forum New To Java
    Replies: 4
    Last Post: 03-08-2010, 07:07 PM
  4. Cannot find symbol variable pD! I cant fix it!!!
    By Addez in forum New To Java
    Replies: 2
    Last Post: 09-17-2009, 08:32 PM
  5. Cannot find symbol variable yourScore
    By Addez in forum New To Java
    Replies: 4
    Last Post: 08-17-2009, 10:48 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •