Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6105717
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T14:00:04+00:00 2026-05-23T14:00:04+00:00

I have tried all that i could to generate the R.java file but in

  • 0

I have tried all that i could to generate the R.java file but in vain. I have just created an android project and while creating the android project it isn’t creating R.java file ! There were compilation errors in my project as i still had to add the android.jar file to my project but even after adding the jar file, cleaning the existing build and again building it didn’t work.

Then i checked the ‘build automatically’ option in eclipse. Even that didn’t help !

Few things to be noted :

1)I have created the android project with build-target android 2.2 and API version 8.

2)I would like to tell is while creating the project it gives an error saying proguard.cfg not found ! I couldn’t locate ‘default.properties’ file to delete the entry which refers to proguard.cfg entry.

3)JAVA_HOME in my environment variables is pointing to jdk1.4. Dunno whether this should be the reason !

4)Contents of

1.main.xml

    <?xml version="1.0" encoding="utf-8"?>
    <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
        android:orientation="vertical"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent"
    >
    <TextView  
        android:layout_width="fill_parent" 
        android:layout_height="wrap_content" 
        android:text="@string/hello"
    />
    </LinearLayout>

2.strings.xml

<?xml version="1.0" encoding="utf-8"?>
<resources>
    <string name="hello">Hello World, HelloAndroidActivity!</string>
    <string name="app_name">Hello, Android !!</string>
</resources>

3.AndroidManifest.xml

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
  package="com.pack.android.test"
  android:versionCode="1"
  android:versionName="1.0">
<uses-sdk android:minSdkVersion="8" />

<application android:icon="@drawable/icon" android:label="@string/app_name">
    <activity android:name=".HelloAndroidActivity"
              android:label="@string/app_name">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

</application>

</manifest>

4.Code for HelloWorldActivity.java

  package com.pack.android.test;

  import android.app.Activity;
  import android.os.Bundle;

  public class HelloAndroidActivity extends Activity {
      /** Called when the activity is first created. */
      @Override
      public void onCreate(Bundle savedInstanceState) {
         super.onCreate(savedInstanceState);
         setContentView(R.layout.main);
      }
   }

Attached are the images for

Folder structure in eclipse (Eclipse 3.6)
res/drawable-hdpi/icon.png
res/drawable-ldpi/icon.png
res/drawable-mdpi/icon.png
Please help me out. I have just started with the Hello World application 🙂

Thanks,
Adithya

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T14:00:04+00:00Added an answer on May 23, 2026 at 2:00 pm

    R.java might not be generated because you have other errors in your code not related to the R file. So check if you have these errors, fix them, and clean your project.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have tried all the solutions that have been provided including using PRAGMA but
i have tried looking online but had no luck, How i could delete all
I have 2 path objects in my android code.I have tried all the way
I have tried almost all the solutions from SO but no success :(. I
I have tried many permutations but they all don't seems to work well. Am
How can I replace all line-endings in big file (>100MB)? I have tried to
I have tried all of these various ways to set the value of the
I have a problem with random number generating in C# I have tried all
I have tried almost all the techniques to apply sticky footer to my site
Questions exactly like this have been asked before, i've read them all and tried

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.