0

Hi all my problem is I was setting the eclipse environment for Ubuntu 13.10 with eclipse, SDK and JDK 7.

Normally when I create New->Android Application Project and going through this process I supposed to see:

  1. Blank Activity
  2. FullScreen Activity
  3. Master/Detail Flow

Problem:

First option (1- Blank Activity) don't show up and I don't know why. I hope anyone can help in this problem or tell me how to create an activity in an empty project.

I've tried:

I tried to install another copy of eclipse and link it with the SDK but that didn't work also.

Jason Aller
  • 3,541
  • 28
  • 38
  • 38
samer226047
  • 125
  • 1
  • 13
  • do you see the options for the other templates? ... for your Question, you can simply create a new Class which is a subclass of activity; overwrite constructor an onCreate() but DONT FORGET to make an entry in the AndroidManifest – Martin Frank Feb 05 '14 at 05:49
  • I created a new empty and I added a java class as activity but it kept give me error in R.java which is auto generated but to be honst i didn't change anything in the ndroidManifest can you tell me what i have to edit in it ? Thanks in advance – samer226047 Feb 05 '14 at 13:50

2 Answers2

0

ok you must extend you AndroidManifest.xml file, the reply function is too small for a full reply, so i'll post this solution :-~

<application
    android:allowBackup="true"
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name"
    android:theme="@style/AppTheme" >
    <!-- Main (starter) Activity -->
    <activity
        android:name="cn.brandhook.apps.MainActivity"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />

            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

    <!-- blank (new created) Activity -->
    <activity
        android:name="cn.brandhook.apps.NewBlankActivity"
        android:label="@string/title_new_blank_activity"
        android:parentActivityName="MainActivity" >
        <meta-data
            android:name="android.support.PARENT_ACTIVITY"
            android:value="MainActivity" />
    </activity>   

</application>

having problems with R.Java not created/reCreated you should check Developing for Android in Eclipse: R.java not regenerating

i guess this won't help you much, but it was supposed to be a mere reply (comment)

Community
  • 1
  • 1
Martin Frank
  • 3,445
  • 1
  • 27
  • 47
0

I just reinstalled Everything and it worked very well. Any way now the official Version for Android Development is Android Studio.

samer226047
  • 125
  • 1
  • 13