I am creating my first Android application, but it does not start at all.
In my src> android.SampleApp, I created a java file called Main.java with:
public class Main extends Activity {
In my res> layout> 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" android:id="@+id/txtContent"/> <Button android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Button One" android:id="@+id/btn1"></Button> <Button android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Button Two" android:id="@+id/btn2"></Button>
My AndroidManifest.xml content is:
<?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="android.SampleApp" android:versionCode="1" android:versionName="1.0"> <application android:icon="@drawable/icon" android:label="@string/app_name"> </application> <uses-sdk android:minSdkVersion="7" />
I get this error:
- [2010-02-02 01:46:26 - SampleApp] Android Launch!
- [2010-02-02 01:46:26 - SampleApp] adb is working fine.
- [2010-02-02 01:46:26 - SampleApp] No Launcher activity found!
- [2010-02-02 01:46:26 - SampleApp] Launch will only synchronize the application package on the device!
- [2010-02-02 01:46:26 - SampleApp] Performing synchronization
Lines 3 and 4 are highlighted in red.
Can someone lead me in the right direction to just show the application on an emulator?
Android 2.1 SDK with Eclipse
android
Shawn mclean
source share