Discussion Forums  >  Uncategorized

Replies: 2    Views: 311

AOK222
Android Fan
Profile
Posts: 1
Reg: Nov 15, 2011
Orlando
510
11/19/11 12:07 PM (14 years ago)

ERROR - Type R cannot be resolved to a variable

When I try and start a new project using the downloaded files from Buzztouch, I get several errors (using Android 1.6 with Google APIs). The first is R cannot be resolved to a variable The second is Error: String types not allowed (at 'layout_height' with value 'match_parent') The third is Error: String types not allowed (at 'layout_width' with value 'match_parent') Any help in fixing these would be greatly appreciated. Thanks
 
DeckG
Aspiring developer
Profile
Posts: 36
Reg: Apr 18, 2012
Oamaru, New Zea...
1,810
like
08/04/12 06:21 PM (13 years ago)
R cannot be resolved to a variable - I just restarted eclipse and am getting this error scattered throughout my files! Any ideas anyone?
 
amnamn
I hate code!
Profile
Posts: 3
Reg: Feb 14, 2012
Provo, UT
1,980
like
12/19/12 02:33 PM (13 years ago)
I know this is an old thread, but I spent several hours trying to figure this one out, so hopefully someone will benefit from this answer. For me (I'm on Windows 7 by the way), I went into the Android SDK manager (If your in Eclipse you go to Windows/Android SDK Manager)and installed the "Android SDK Platform-tools." I'm brand new at this (just started yesterday) so I don't know why this fixed my problem, but it did. Hope this helps. -Ammon
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.