0

I am using Eclipse Juno IDE for my android development. I recently installed the latest ADT 22.0.0 plugin. After that I am facing an issue.

Whenever I create a new application, R.java file is automatically deleted. For existing projects which have had no issues, R.java file is getting deleted when Build the project or clean it.

I have tried my best to sort out this issue, and it still exists. Has anybody faced or facing similar issue?? Is there a way this can be resolved ?? Any suggestions out there...

I am giving minSdkVersion="8" and targetSdkVersion="17"

Please help at the earliest possible.

Justin
  • 1
  • 2
  • 3
    It's one of the most common problems in ADT 22. Try [this](http://stackoverflow.com/questions/16608524/eclipse-giving-error-missing-r-java-file-after-recent-update/16608570#16608570) or [this](http://stackoverflow.com/questions/16610190/classnotfoundexception-after-adt-update/16610247#16610247). – Krauxe May 20 '13 at 11:43
  • This may help you : http://stackoverflow.com/questions/16623439/r-java-does-not-regenerate-in-any-way/16623470#16623470 – Alexis C. May 20 '13 at 11:43
  • Thanks to all.. The issue is now resolved... I just updated the SDK and bingo... the issue is gone – Justin May 20 '13 at 12:03

1 Answers1

0

is it for one project or all the project? I hope its happening for the single new project you are trying to create.

Usually this error occurs when you have errors in your xml files. Please go through your xml files to see if there are any errors. Once you fix any errors in the xml files check your source files and remove any reference to the R file. Remove any import that references the R file.

Now re-build your project. It should work now I suppose.

Update

Ok it's an issue with the new SDK follow this answer to solve your issue.

Community
  • 1
  • 1
Jay Mayu
  • 17,023
  • 32
  • 114
  • 148
  • 1
    Hi Mayu... Thanks for your reply... Initially I thought of errors in XML file, but could not find any. When I tried to create a new application with Blank Activity through the wizard, the R.java file is deleted immediately after the application is created. I am confused here... How a newly created activity can have errors in XML...? – Justin May 20 '13 at 11:49
  • @Justin yeah if its a new project then you can't have errors in it.did you check this [answer](http://stackoverflow.com/questions/16608524/eclipse-giving-error-missing-r-java-file-after-recent-update/16608570#16608570) – Jay Mayu May 20 '13 at 11:55