Friday, May 27, 2011

Error: Unable to open class file R.java and How to fix it.





[2011-05-27 12:12:39 - listActivity] ERROR: Unable to open class file /root/workspace/Manifest.java: No such file or directory

[2011-05-27 13:50:38 - listActivity] ERROR: Unable to open class file /root/workspace//R.java: No such file or directory




R.java and Manifest.java is a automatically generated file.


The ADT has a few such annoying bugs. But you can sort them out..
What usually helps is:



1. Close Project->Open Project > Build Automatically .
2.Another thing that sometimes helps is right click project > android tools > fix project properties and remove unnecessary content or jar files.

3.Or you can do Project->clean and Refresh .




If still it not generating R.java files then check your class there must be a extra line..

Import R.java.*; Remove that and then do all the above one by one..

Hope it help ..

If someone know other way please let me know.

Thanks

 

2 comments:

  1. Check your package name too in the AndroidManifest.xml file...

    ReplyDelete
    Replies

    1. Nhạc Thành khẽ nói, hắn không ngờ mưới mấy năm không gặp, tỷ tỷ của mình ngày càng trở nên thành thục quyến rũ.

      - Biểu ca, chúng ta phải đi cứu hai người bọn họ.

      Lệnh Hồ Hạo Thiên và Lệnh Hồ Hạo Thiên cũng cất tiếng nói, đối với hai người bọn họ lúc nàydongtam
      mu private
      tim phong tro
      http://nhatroso.com/
      nhac san cuc manh
      tổng đài tư vấn luật
      http://dichvu.tuvanphapluattructuyen.com/
      văn phòng luật
      tổng đài tư vấn pháp luật
      thành lập công ty
      http://we-cooking.com/
      chém gió
      trung tâm ngoại ngữ, người mà bọn họ kính nể nhất là vị biểu ca này.

      Ở nơi này một tháng, Nhạc gia mọi người được Nhạc Cốc và Khiếu Thiên Hổ giải thích đã biết được mối quan hệ giữa Tứ Đại Nhân Tộc, Tam Đại Thú Tộc và Hắc Ám Thần Điện trong đó, Viễn Cổ Hổ Tộc tại sao lại tới Huyền thiên đại lục.

      - Chúng ta trở về Song Phong thành trước sau đó tới Viễn Cổ Hổ Tộc cứu người.

      Nhìn Lệnh Hồ Hạo Thiên và Lệnh Hồ Huyền Tố hai người mấy năm không gặp ngày càng trưởng thành, Nhạc Thành cũng hơi kinh ngạc.

      Delete

How TOPT Works: Generating OTPs Without Internet Connection

Introduction Have you ever wondered how authentication apps like RSA Authenticator generate One-Time Passwords (OTPs) without requiring an i...