Results 1 to 4 of 4
  1. #1
    kiddCOWBOYY is offline javaNOOB
    Join Date
    Mar 2012
    Location
    Texas
    Posts
    16
    Rep Power
    0

    Default Need Help with program

    hello all, so yesterday i decided i want to start messing around with building apps, so i got all the stuff i needed for building android apps and i began working on the basic hello world app, i have it finished but there is an error popping up that i don't understand can yall help?


    Java Code:
    package HelloWorld;
    
    import android.app.Activity;
    import android.os.Bundle;
    import android.widget.TextView;
    
    
    public class HelloWolrdActivity extends Activity {
        /** Called when the activity is first created. */
        @Override
        public void onCreate(Bundle savedInstanceState) {
            super.onCreate(savedInstanceState);
            //setContentView(R.layout.main);
            TextView tv = new TextView(this);
            tv.setText("Hello Android");
            setContentView(tv);
        }
    }
    and here is my error

    [2012-04-10 13:03:26 - HelloWolrd] Application package 'AndroidManifest.xml' must have a minimum of 2 segments.

    please help :P
    thanks
    Cowboy

  2. #2
    eRaaaa is offline Senior Member
    Join Date
    Oct 2010
    Location
    Germany
    Posts
    787
    Rep Power
    6

    Default Re: Need Help with program

    If the error message says something about AndroidManifest.xml in conjunction with "must have..." do you think it would be useful to post the contents of this file? :)

  3. #3
    kiddCOWBOYY is offline javaNOOB
    Join Date
    Mar 2012
    Location
    Texas
    Posts
    16
    Rep Power
    0

    Default Re: Need Help with program

    iam not sure i understand ???

  4. #4
    eRaaaa is offline Senior Member
    Join Date
    Oct 2010
    Location
    Germany
    Posts
    787
    Rep Power
    6

    Default Re: Need Help with program

    There must be a AndroidManifest.xml file in your android project!
    The AndroidManifest.xml File | Android Developers
    Read this and post the content of your file.

    Example:
    Java Code:
    <?xml version="1.0" encoding="utf-8"?>
    <manifest xmlns:android="http://schemas.android.com/apk/res/android"
          package="HelloWorld"
          android:versionCode="1"
          android:versionName="1.0">
        <uses-sdk android:minSdkVersion="8" /> <!-- change here ??? -->
        <application android:icon="@drawable/icon" android:label="@string/app_name"><!-- change here -->
            <activity android:name=".HelloWolrdActivity"
                      android:label="@string/app_name"> <!-- change here ??? -->
                <intent-filter>
                    <action android:name="android.intent.action.MAIN" />
                    <category android:name="android.intent.category.LAUNCHER" />
                </intent-filter>
            </activity>
    
        </application>
    </manifest>

Similar Threads

  1. Replies: 2
    Last Post: 04-02-2011, 12:57 PM
  2. Replies: 13
    Last Post: 03-22-2011, 06:49 AM
  3. changing my program to array working program
    By Chewart in forum New To Java
    Replies: 39
    Last Post: 11-18-2009, 06:53 PM
  4. Replies: 0
    Last Post: 04-04-2008, 02:40 PM
  5. Replies: 0
    Last Post: 10-04-2007, 09:33 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •