THX FOR THE VID! plz subscribe to me! i m new to youtube and have posted 1 video but its a rly useful tutorial for getting free music on an iDevice! plz watch and rate and im sry im not trying to spam!
I'm a brazilian student... After 3 day search for tutorials and vids about Android Development i found your channel, your work is awesome, very simple, direct e cool... And the most important your diction is very good!
Yet another fix for the R.java: Look in the main.xml and take out any errors. The errors prevent the R.java from generating, which causes the error in the IDs.
@lolfag93 clean removed my R as well at first but later it works fine,,this error is only because of missing R,,restore it somehow(best way is to create new project for new programmers) then start programming again by copying previous code
On My StartinPoint thingy the "setContentView(R.layout.main);" the "main" at the end isn't blue like it is in this video, does that mean it's not actually linked to the main.xml?
I can't figure this out the (R.id.) thing i have tried "Save All", the Clean Project, and made sure it's a plus sign yet still no success please can someone help me.
Heya, for all of you getting the R.id error also after hitting "save all" button, the solution might be cleaning the project (Project -> Clean...). It worked for me! If it works for you too gimme some thumbs up for visibility :]
Hmm, I have the ID prblem aswell. I have had a read through half of the comments. I have the + on the main.xml and i have saved my work. Yet it still says cannot be resolved or is not a field. The bADD and bSUB arent in that autocomplete like it says on the video, Would this be something to do with declaring it somehiow. But as i said i have added that + to it. Thanks
Also when making changes to folders in your (named) project workspace. Like adding MP3's or images you must clean your project. Once your files are in place, then in Eclipse under the Project tab click clean and your files will appear. All files added to your project must be placed in your (named) workspace not through Eclipse. Again I hope this helps a bit.
Hello All, You must make sure you save as you go along. Or it will throw error messages on your code even though it is identical to what your seeing in the tutorial. The system only reads what is saved. Once it is everything will link together. You can either save all. Or there is also an indicator on the tab itself. If you see an * on the tab then there is unsaved code in that specific file. I hope this helps a bit.
This is a great tutorial, but im sad that you had to explain java as if we're all beginners. If you want to learn java, watch the tutorials for java before starting on android!
Saving main.xml fixed the R.id problem for me too, thanks guys it was starting to get me down, not having done any of this before - and great tutorials btw, maybe could do with updating for the new software builds ?
@walker1054 Save all grayed out. I went through each file I edited and saved individually and still have the error that others are having with the R.id.
hey for everyone who is going crazy with the R.id error, i went through a bunch of these comments and every basically has some sort of solution, and one of those is bound to work for you, bu ill add mine because i couldnt find my solution anywhere, so anyways, what i did was open up the strings.xml file from package explorer and i noticed there was an error there, fix the error if you have one, it might not work though, so the next thing i did was attempt to create a new string, not from
@dvzqz87 the string creater interface but the actually string.xml source code, for WHATEVER reason, i have no fucking idea, for whatever reason, after attempting to do that, and then immediately deleting it.. then saving.. it took away my error.. so add this to the list of solutions for this ridiculously annoying error! have fun
ok guys here was what it was for me . spent a couple of hours on this . There was an error in the xml file that i had not seen since XML grpahically shows automatically.
1. In R.java can you see the method final class id ? if you get the R.id ERROR it means you probably cannot see this id .
2. correct the xml - triple check this .
3. WINDOW-> CLEAN to remove the files java creates such as gen->R.java
4. window->Build project ; R.javacreates with classid
I tried all the troubleshooting steps I could find and the only thing that worked for me was changing the line "import android.R" at the top to "import *yourpackagenamehere*.R" with no stars
You can find you package name at the very top of the java code... Thumbs up if this helped
Here IS the solution to the R.id error in that your bAdd and bSub are not recognized.
This is most likely due to the fact that you do not have SWT installed.
If you go to 0:01 you'll see thenewboston has many other Form Widgets installed, including BUTTON, what we're creating.
To check if you have this just navigate to the same page he's on and see if Button is listed. If not you will need to install SWT, I found a good tutorial here which fixed this problem for me. goo. gl/ny9Os
@TheTizzyTiz ty for the reply on the link for Android tutorial.. I was able to find my problem. I had to go up and click File and Save All. I tried just saving the .xml like someone else had suggested, watched the tutorial you recommended. Then out of ideas, I went up and "saved all"........problem fixed!.
Anyway, I wanted to thankyou for the help and also let you know how I was able to finally get it fixed just in case you didn't already know that.
For those who still have the R.id problem, try saving the XML file after editing it during Tutorial 7. The problem should have solved itself after saving the XML file.
Hi Guys , For the R.id error , you might as well click on "save all", to save all files (including main.xml) in the project before typing R.id. I believe , eclipse can't recognize the created xml ids if you did not save the main.xml file. Pressing "save all" worked for me. Hope it clarifies the reason we got that error message.
@DelaNation Thanks a lot :) i downloaded all these videos and whenever i run into a problem i come to the youtube comments for the video and theres always what im looking for in the Top Comment section. thanks:)
Nothing here worked for me, until I noticed the line 'import android.R;' in my startingPoint.Java. I removed that line and the errors went away, hope this helps.
For anyone that's tried everything else listed here to no avail for the R.id error--
This is a simple mistake but, make sure that in your main.xml file within the code for each Button you do not have a closing bracket directly after the title text 'Add One' & 'Subtract One'
When he demonstrates in the last video--he previews the graphical UI after closing that set of lines, but returns to add more information for each button and while doing so moves the closing bracket down to the very end.
1.) Completely rewrite the code in a new project. (Lots of copy and pasting, but carefully inspect for syntax errors.)
2.) Click the error icon next to the line number (it should give you a pop up list of options) and click "create constant field for .id" (or something along those lines, I don't remember the exact wording.)
3.) Save all. You should get a series of errors, but this just means that your R file is fixing itself.
Does anyyone have a Solution to the R.id.sAdd, probleem please shaare, I have tried everything from closing and opening the R.java file, comenting and what not... and still nothing
People having the "R.id " error just recheck your main.xml file.. run it and check the errors i had a error "textsize" so i replaced it to "textSize" , Case sensitive stuff :P
Great tutorials dude! I have a programming background doing a lot of PHP and some other languages but Java has always scared me! At least in PHP you have an option of using classes or not! Hahah.
Anyway your guides are extremely helpful and easy to follow/catch on.
You can subscribe to this playlist. Click on "Android Application Development Tutorials (thenewboston)" playlist link under my comment. Thumbs up to help others!
@pchelper102: I had the same problem. Make sure you save the main.xml in the res/layout folder before you move on to doing that findViewById() stuff. Hope that helps!
@Muse94Muse You should not edit the R.java file as it is automatically created. In XML file, delete the bAdd and bSub, save everything. Then try defining the bAdd and bSub again... Hope it helps
@coollavanya1997 would you please tell me how to open R.java file ? cause i think i did and still can't see the options of bAdd and bSub available! thanks
@coollavanya1997 Can you help me please it gives me the error on the .id part in other words the red line is one the .id part the error says "Cannot be Resolved or is not a field" any suggestions plz!
i don't know how many people this is going to help, but if you want to automatically import things (trust me in the future you will import a TON of things) hit the shortcut - CMD SHIFT O, or on windows i think its CTRL SHIFT O {thats o as in the letter}
@dirnol You are the MAN!!! you saved my three day old confusion.... It was so silly of me not to have SAVED THE XML FILE and search the entire internet for a solution. I simply don't know how to thank you!!! Guys Thumbs up dirnols comment so that people can save time :)
THX FOR THE VID! plz subscribe to me! i m new to youtube and have posted 1 video but its a rly useful tutorial for getting free music on an iDevice! plz watch and rate and im sry im not trying to spam!
THX!
TheExtremeDevice 10 hours ago
hey i wasnt able to find the .java src file. I did all the step you made, should i just make a new class to replaces that file?
cordarro100 1 week ago
Hello.
I'm a brazilian student... After 3 day search for tutorials and vids about Android Development i found your channel, your work is awesome, very simple, direct e cool... And the most important your diction is very good!
Thanks a lot!
lestatjf 1 week ago in playlist TheNewBoston - Android Application Development
i reccomend watching thenewbostons java tutorials cause it is too difficult otherwise also google xml tutorials.
doubleaichh 2 weeks ago
Yet another fix for the R.java: Look in the main.xml and take out any errors. The errors prevent the R.java from generating, which causes the error in the IDs.
black4ty 2 weeks ago
ok here is how it works for R.id.bAdd error,.,
1) DO NOT IMPORT 'R' (or mess with it like he said)
2) IF YOU HAVE CREATED 'raw' AND 'layout-landscape' folders DELETE THEM (if it's showing errors)
3) SAVE ALL and CLEAN (inside PROJECT)
4)try code now,if it still not working
5)CHECK WHETHER YOU HAVE 'R' where it shud belong (gen->ur project name);
6)IN CASE ITS NOT THERE copy ur code to some text file and CREATE NEW PROJECT
7)NOW IT WORKS ,.,
ujwalvail 3 weeks ago 4
@ujwalvail I did all those things it still doesn't work, clean, somehow removed my R file
lolfag93 2 weeks ago
@lolfag93 clean removed my R as well at first but later it works fine,,this error is only because of missing R,,restore it somehow(best way is to create new project for new programmers) then start programming again by copying previous code
ujwalvail 2 weeks ago
This has been flagged as spam show
@ujwalvail thnxs a lot,it really works for me:)
titli4fly1 2 weeks ago
Still cannot solve this problem add=(Button) findViewById(R.id.bAdd);
every time it shows that id cannot be resolved or not a field.
plz anyone suggest be step by step what to do since i m very new in android.thnk u
titli4fly1 3 weeks ago
I started watching these tutorials and have to say - they are very very clear and easy to follow. Brilliant work !
Protheus1975 3 weeks ago
On My StartinPoint thingy the "setContentView(R.layout.main);" the "main" at the end isn't blue like it is in this video, does that mean it's not actually linked to the main.xml?
aidansbox94 4 weeks ago in playlist The new boston
I facepalmed once he started explaining an integer. This aint beginner java!!!
xSaucecode 1 month ago in playlist Android Application Development Tutorials
add @+id/ to your id's EX. "@+id/MY_BUTTON"
Swavethex7masterboom 1 month ago in playlist Android Application Development Tutorials
remove
android:text_size fields in buttons and save project to fix errors
devilazpl 1 month ago
To solve problem with main.XML (can't resolve)
try to replace:
import android.R;
with:
import your.application.packagename.R;
I think this will solve problem with main.xml
EngMukhtar 1 month ago in playlist TheNewBoston - Android Application Development
I can't figure this out the (R.id.) thing i have tried "Save All", the Clean Project, and made sure it's a plus sign yet still no success please can someone help me.
Thank You :)
aidansbox94 1 month ago
For the most part
johnnydicamillo 1 month ago
Heya, for all of you getting the R.id error also after hitting "save all" button, the solution might be cleaning the project (Project -> Clean...). It worked for me! If it works for you too gimme some thumbs up for visibility :]
youphate 1 month ago 8
@Jpoulte ME TOO! I have followed all the directions to the T! IDK what I am doing wrong and it sucks being "stuck". I posted in their forum.
Any help would mean a lot!
BlakeAttebury 1 month ago
@BlakeAttebury PS. ANYONE who would be willing to help me, it would mean a lot to me! Please message me. Thank you in advance.
BlakeAttebury 1 month ago
Hmm, I have the ID prblem aswell. I have had a read through half of the comments. I have the + on the main.xml and i have saved my work. Yet it still says cannot be resolved or is not a field. The bADD and bSUB arent in that autocomplete like it says on the video, Would this be something to do with declaring it somehiow. But as i said i have added that + to it. Thanks
jpoulte 1 month ago
id say you need a base knowledge of java to move onto android java :P
unknown0man 1 month ago in playlist Android Application Development Tutorials
Awesome mate! thank you!
julayterobias 1 month ago
This episode ended on a major cliffhanger. Can't wait to see the next one!
TTV5 1 month ago
If the R.id is not working go to main.xml and check the "@+id/tvDisplay" it needs a PLUS SIGN
vercoelenmike 2 months ago
@vercoelenmike thanks ive been look for a solution
iPodjbG33K 1 month ago
This has been flagged as spam show
Hello Sir i am getting R.id error its says id cannot be resolved or not in a field. plz help me wht to do.
zameelrs 2 months ago
Hello Sir i am R.id error its says id cannot be resolved or not in a field. plz help me wht to do.
zameelrs 2 months ago
@zameelrs yes, I'm having the same issues. Save all didn't work for me
myferret 1 month ago
Also when making changes to folders in your (named) project workspace. Like adding MP3's or images you must clean your project. Once your files are in place, then in Eclipse under the Project tab click clean and your files will appear. All files added to your project must be placed in your (named) workspace not through Eclipse. Again I hope this helps a bit.
Torndaddy 2 months ago in playlist TheNewBoston - Android Application Development
Hello All, You must make sure you save as you go along. Or it will throw error messages on your code even though it is identical to what your seeing in the tutorial. The system only reads what is saved. Once it is everything will link together. You can either save all. Or there is also an indicator on the tab itself. If you see an * on the tab then there is unsaved code in that specific file. I hope this helps a bit.
Torndaddy 2 months ago in playlist TheNewBoston - Android Application Development
save all works, thank u, and travis dont miss out on such important things !
paramshah25 2 months ago
"id cannot be resolved or is not a field"
help ! (R.id. error error..
paramshah25 2 months ago
"like wow what´s going on" lol
wtfucrazy 2 months ago
void aaa
prashhu007 2 months ago
yo guys this is what i did to fix the solution and it worked i saw some imports of r i deleted it then it worked try it out
TeamTwizers 2 months ago in playlist Android Application Development Tutorials
The error which some people are occuring in the R.id.** line's fix is by saving all then closing the windows and reopening them
firesoccer55 2 months ago in playlist Android Application Development Tutorials
Great one
maximum20lettershere 2 months ago
Save all worked perfect for me. Thanks everyone
jspina95 2 months ago
the R.id.bAdd my id is like red underlined saying its wrong how i fix dis stupid shit and is the id necessary
GModPlyr 2 months ago in playlist Android tuts
you r awesome! for the most part :D
Jdjagjmdat 2 months ago
This is a great tutorial, but im sad that you had to explain java as if we're all beginners. If you want to learn java, watch the tutorials for java before starting on android!
TehGameMaker 3 months ago
> "Void, Ah!"
I lawled
MrMelonBread 3 months ago in playlist Android Application Development Tutorials
hey when i works on java the autocompletion feature of eclipse works
but in android programing it is not working
can anybody help me??
saurav862 3 months ago
@saurav862 Hit Ctrl + Space for intelesense to pop up at any given point while coding
MrMelonBread 3 months ago in playlist Android Application Development Tutorials
Saving main.xml fixed the R.id problem for me too, thanks guys it was starting to get me down, not having done any of this before - and great tutorials btw, maybe could do with updating for the new software builds ?
Detectionable 3 months ago
got a error on add=(Button) findViewById(R.id.bAdd);
// error is id cannot be resolved or is not a field
nikhil200924 3 months ago
@nikhil200924 Check the top comments on this video. Right at the top, cant miss them. Basically click file/ save all
walker1054 3 months ago in playlist Android Application Development Tutorials
@walker1054 Save all grayed out. I went through each file I edited and saved individually and still have the error that others are having with the R.id.
tsolorio3001 3 months ago
@walker1054 Nevermind. I was missing the plus sign in main.xml where it says android:id. Sometimes autocomplete bites you in the rear. :(
tsolorio3001 3 months ago
hey for everyone who is going crazy with the R.id error, i went through a bunch of these comments and every basically has some sort of solution, and one of those is bound to work for you, bu ill add mine because i couldnt find my solution anywhere, so anyways, what i did was open up the strings.xml file from package explorer and i noticed there was an error there, fix the error if you have one, it might not work though, so the next thing i did was attempt to create a new string, not from
dvzqz87 3 months ago
@dvzqz87 the string creater interface but the actually string.xml source code, for WHATEVER reason, i have no fucking idea, for whatever reason, after attempting to do that, and then immediately deleting it.. then saving.. it took away my error.. so add this to the list of solutions for this ridiculously annoying error! have fun
dvzqz87 3 months ago
Anyone else get the findViewByID error?
SchMasHed 3 months ago 2
Save the main.xml file and that should fix the R.id error
11m0 4 months ago in playlist Android dev
Best tutorials i ever seen
emersonetns 4 months ago
I got my R.id error fixed after i restarted my computer, strange enough.
snx90fma 4 months ago
lol ppl here are so motivated and I feel like I can see sparkles from their eyes. BTW i came from 110th tut
Mrgreatestfreakout 4 months ago in playlist TheNewBoston - Android Application Development
very clear
praveenchukka 4 months ago
ok guys here was what it was for me . spent a couple of hours on this . There was an error in the xml file that i had not seen since XML grpahically shows automatically.
1. In R.java can you see the method final class id ? if you get the R.id ERROR it means you probably cannot see this id .
2. correct the xml - triple check this .
3. WINDOW-> CLEAN to remove the files java creates such as gen->R.java
4. window->Build project ; R.javacreates with classid
govindakeshavdas 4 months ago in playlist Android Application Development Tutorials
Comment removed
zmijosvinja 4 months ago
I tried all the troubleshooting steps I could find and the only thing that worked for me was changing the line "import android.R" at the top to "import *yourpackagenamehere*.R" with no stars
You can find you package name at the very top of the java code... Thumbs up if this helped
Dizle09 4 months ago
Tadas156 all u need to do is capitalize the B for button.
shaxaary1 4 months ago
@shaxaary1 how to do it ? :)
tadas156 4 months ago
3:46 on my pc it dont shows import textview it only shows create class textView
tadas156 5 months ago
This has been flagged as spam show
All you have to do to fix the R.id error is press save all. Thumbs up so everybody can see
440DECA 5 months ago in playlist More videos from thenewboston
I love this tutorials.
nikhiljoshiwit 5 months ago
My fix for the R.id problem: With your Main.xml file I had a Main.out.xml file. I just had to delete that one :)
MrNovermars 5 months ago
Comment removed
specthanatos 5 months ago
Just build the project to fix the problem with R.id. It works for me. Cheers!
V1KHay 5 months ago in playlist TheNewBoston - Android 2
Here IS the solution to the R.id error in that your bAdd and bSub are not recognized.
This is most likely due to the fact that you do not have SWT installed.
If you go to 0:01 you'll see thenewboston has many other Form Widgets installed, including BUTTON, what we're creating.
To check if you have this just navigate to the same page he's on and see if Button is listed. If not you will need to install SWT, I found a good tutorial here which fixed this problem for me. goo. gl/ny9Os
TheTizzyTiz 6 months ago
@TheTizzyTiz where did you see the tutorial on how to add SWT?? I am having the id issue. Any help would be appreciated, cause I am stuck!
mtommy71 5 months ago
@mtommy71 goo. gl/ny9Os
Try that link but delete the space between the . & the g, sorry, YouTube don't allow links in their comments so I had to put it in separated.
TheTizzyTiz 5 months ago
@TheTizzyTiz ty for the reply on the link for Android tutorial.. I was able to find my problem. I had to go up and click File and Save All. I tried just saving the .xml like someone else had suggested, watched the tutorial you recommended. Then out of ideas, I went up and "saved all"........problem fixed!.
Anyway, I wanted to thankyou for the help and also let you know how I was able to finally get it fixed just in case you didn't already know that.
mtommy71 5 months ago
For those who still have the R.id problem, try saving the XML file after editing it during Tutorial 7. The problem should have solved itself after saving the XML file.
Thumbs up so that people can see and get help.
LeeRyan94 6 months ago 3
R.id error any sloutions ??? R.java file doesnt have bAdd or bSub
??
anujtab 6 months ago
R.id error any sloutions ??? R.java file doesnt have bAdd or bSub
anujtab 6 months ago
I fixed it by going one episode backwards and creating a whole new project, writing everything new and it worked
borkov4e 6 months ago
Hi Guys , For the R.id error , you might as well click on "save all", to save all files (including main.xml) in the project before typing R.id. I believe , eclipse can't recognize the created xml ids if you did not save the main.xml file. Pressing "save all" worked for me. Hope it clarifies the reason we got that error message.
DelaNation 6 months ago 36
@DelaNation <---- what he said.
itsimaginationtime 6 months ago
@DelaNation Yes the main reason behind R.id error they all are not saving all the files
absar45 6 months ago in playlist TheNewBoston - Android 11
@DelaNation Thanks a lot :) i downloaded all these videos and whenever i run into a problem i come to the youtube comments for the video and theres always what im looking for in the Top Comment section. thanks:)
walker1054 3 months ago in playlist Android Application Development Tutorials
@DelaNation
thx.. it worked!
Baaataaataaa 1 month ago in playlist Android Application Development Tutorials
Comment removed
titli4fly1 2 weeks ago
my mistake, i had used '=' instead of '+' while setting up the ids
and i had not saved my main.xml yet (don't if that mattered), but its worth a try for anyone trying to fix R.id error
lalitmali 6 months ago in playlist Android Application Development Tutorial
Nothing here worked for me, until I noticed the line 'import android.R;' in my startingPoint.Java. I removed that line and the errors went away, hope this helps.
MCVenomOS 6 months ago
I tried every single thing in the comments and the problem doesn't go away!
xsannyx 6 months ago
For anyone that's tried everything else listed here to no avail for the R.id error--
This is a simple mistake but, make sure that in your main.xml file within the code for each Button you do not have a closing bracket directly after the title text 'Add One' & 'Subtract One'
When he demonstrates in the last video--he previews the graphical UI after closing that set of lines, but returns to add more information for each button and while doing so moves the closing bracket down to the very end.
54626 6 months ago
The solution to this problem is that you simply click Project>Clean.
Worked first time for myself.
MrWolfChief 6 months ago in playlist TheNewBoston - Android
@MrWolfChief i did this and i got errors for ALL of my classes now.
HypnotizeCampPosse 6 months ago in playlist TheNewBoston - Android
@HypnotizeCampPosse apparently my R.java file is just gone now...? what?
HypnotizeCampPosse 6 months ago in playlist TheNewBoston - Android
1.) Completely rewrite the code in a new project. (Lots of copy and pasting, but carefully inspect for syntax errors.)
2.) Click the error icon next to the line number (it should give you a pop up list of options) and click "create constant field for .id" (or something along those lines, I don't remember the exact wording.)
3.) Save all. You should get a series of errors, but this just means that your R file is fixing itself.
This worked for me, at least. Hope this helps!
tapplewhack 6 months ago
Does anyyone have a Solution to the R.id.sAdd, probleem please shaare, I have tried everything from closing and opening the R.java file, comenting and what not... and still nothing
Rayden150 6 months ago
The app didn't work. There is an error on lines 21, 22, and 23. My code says:
add = (Button) findViewById(R.id.bAdd);
But it looks like the error is on the "id" in "R.id.bAdd". When I click on the error icon on the line number, it gives me 3 problems:
- id cannot be resolved or is not a field
- bAdd cannot be resolved or is not a field
It does this for every line with an R.id.(insert value here). I have tried opening the R.java file but there are no bAdd and bSub options.
tapplewhack 6 months ago in playlist TheNewBoston - Android
People having the "R.id " error just recheck your main.xml file.. run it and check the errors i had a error "textsize" so i replaced it to "textSize" , Case sensitive stuff :P
NiEHANT 6 months ago
Comment removed
YHCityboy 6 months ago
Comment removed
YHCityboy 6 months ago
Comment removed
pichakjoon 6 months ago in playlist Android Application Development Tutorials (thenewboston)
Great tutorials dude! I have a programming background doing a lot of PHP and some other languages but Java has always scared me! At least in PHP you have an option of using classes or not! Hahah.
Anyway your guides are extremely helpful and easy to follow/catch on.
Pendemic 6 months ago in playlist TheNewBoston - Android
"... void, WHAA!"
MrGodiskungen1 6 months ago in playlist TheNewBoston - Android
It does not help me to save main.xlm I still get error under "id" I think there is something missing in my R.java file..
Anondody 6 months ago
Comment removed
maradona640 6 months ago
this is really irritating if you already know how java works
plutgamer 6 months ago
You can subscribe to this playlist. Click on "Android Application Development Tutorials (thenewboston)" playlist link under my comment. Thumbs up to help others!
xGrowler 6 months ago in playlist Android Application Development Tutorials (thenewboston) 2
If the id comes with an error, comment out that line and just run the app once. It will create the ids when it runs.
kopilatis10 6 months ago 4
@pchelper102: I had the same problem. Make sure you save the main.xml in the res/layout folder before you move on to doing that findViewById() stuff. Hope that helps!
ErichLancaster 6 months ago 3
To fix the R.id error, Just open R.java file once... Then there will be bAdd and bSub options available.. Thumbs up so everybody can get some help
coollavanya1997 6 months ago 55
Comment removed
marcosGarcia14 6 months ago
@coollavanya1997 that didn't work for me...
what is the code that should be in the R.java file?
Muse94Muse 6 months ago 3
@Muse94Muse You should not edit the R.java file as it is automatically created. In XML file, delete the bAdd and bSub, save everything. Then try defining the bAdd and bSub again... Hope it helps
coollavanya1997 6 months ago
@coollavanya1997 i just started all over again from part 1 and now it works :P
Muse94Muse 6 months ago
@coollavanya1997 would you please tell me how to open R.java file ? cause i think i did and still can't see the options of bAdd and bSub available! thanks
haflbreeds 6 months ago
@haflbreeds Just double click R.Java file and then go back to the startingpoint.java
coollavanya1997 6 months ago
Comment removed
ThePhilosophyBoy 6 months ago in playlist Android Application Development
@coollavanya1997 where can i find R.Java file?
haflbreeds 6 months ago
@haflbreeds In Application name > gen > com.app > R.java
coollavanya1997 6 months ago
@coollavanya1997 Still doesn't work for me, I opened and saved all files and still doesn't have these buttons available :(
Nutriment6464 6 months ago
@Nutriment6464 Try starting from scratch :(
coollavanya1997 6 months ago
@coollavanya1997 Can you help me please it gives me the error on the .id part in other words the red line is one the .id part the error says "Cannot be Resolved or is not a field" any suggestions plz!
Rayden150 6 months ago
@Rayden150 Open R.java and then save everything and quit. Open again and it should work...
coollavanya1997 6 months ago
@coollavanya1997 <3333 His worked.
PacoTehTacoMan 6 months ago
@coollavanya1997
Hi I did exactly what you said but it still won't show up. There is no id listing in my R.java file at all...
Pendemic 6 months ago in playlist TheNewBoston - Android
@Pendemic Then in StartingPoint.Java delete the bAdd and bSub code and then add it again, save and quit. Open again and it should work :)
coollavanya1997 6 months ago
I did exactly what you did but the id after the R comes up with an error what should i do
pchelper102 6 months ago 12
@pchelper102 same thing here
lynadagreat 6 months ago
@pchelper102 Try to save what you did in the XML code before proceeding to the .java code!
TheArthurAM 6 months ago in playlist TheNewBoston - Android
@TheArthurAM This worked for me, thanks!
steinman17 6 months ago in playlist TheNewBoston - Android
1:32 "we are gonna keep track of our turtle" :D
xXxDiukexXx 6 months ago
"main cannot be resolved or is not field",,,,,, help
kld0093 6 months ago
when he said "have a good one I just took a donut from the fridge"
zaceezacee 6 months ago
You can press Ctrl+shift+O to import everything needed without having to hover over everything and clicking the import line
mangopearandapples 6 months ago 4
@mangopearandapples
Awesome! Thanks!
MattNTiffany 6 months ago
@mangopearandapples Awesome, thanks!
dabu002 6 months ago in playlist Android Development thenewboston
To fix the findViewById error change import Android.R; to import (project name).R :D hope this helps people!
97273998 6 months ago
I am getting an error on setContentView(R.layout.main); and on add = (Button) findViewById(R.id.bAdd); what do i do?
97273998 6 months ago
help me guys.... my findByViewId is returning null :( what to do????
aki25rulz 6 months ago
@aki25rulz change import android.R; to import (project name).R :D
97273998 6 months ago
i don't know how many people this is going to help, but if you want to automatically import things (trust me in the future you will import a TON of things) hit the shortcut - CMD SHIFT O, or on windows i think its CTRL SHIFT O {thats o as in the letter}
it automatically imports everything you need :D
Flubadoodoo 6 months ago
what i'm i doing wrong android:id="@+id/tvDisplay"
display = (TextView) findViewById(R.id.tvDisplay); just doesn't work
dillyo09 6 months ago 2
Thumbs up for amazing tutorials. These are awesome so far!
McVittie9 6 months ago 2
if you're getting an error under id, that says you need to create and id, make sure you save your main.xml file.
dirnol 6 months ago 3
@dirnol I saved the file but still having an error!
If you mean set up by doing: "andriod:id="@+id/tvDisplay" I have done that...
So why don't it work? o_o
GeekyMe97 6 months ago 2
@GeekyMe97 if that's actually what you did it's cause you spelled android wrong.
ThePheonic 6 months ago
@ThePheonic Oh lol >_<
Thanks ^^
GeekyMe97 6 months ago
@dirnol You are the MAN!!! you saved my three day old confusion.... It was so silly of me not to have SAVED THE XML FILE and search the entire internet for a solution. I simply don't know how to thank you!!! Guys Thumbs up dirnols comment so that people can save time :)
arseshan 6 months ago
@7Mehtab :( well, it doesnt matter xD
kobbsy 6 months ago
first!
kobbsy 6 months ago
@kobbsy nope third!
7Mehtab 6 months ago
9 more to go for 2000! Awesome!
7Mehtab 6 months ago
Hi, im first... yeah.... lol..hate that, good stuff men, good stuff! keep it up!
jeeeerpa 6 months ago 2
@jeeeerpa congratz!
7Mehtab 6 months ago