I think I used inappropriate terminology. I am getting an exception
during runtime (as soon as it starts).

my java code is:

package com.google.begin1Package;

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





public class begin1Activity extends Activity {

    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle icicle) {
        super.onCreate(icicle);
        String ogres[]= {"Shrek", "Fiona", "ThrowBack"};


        ArrayAdapter <String>arrayAdapter1= new ArrayAdapter
<String>(this, R.layout.customlayout);
        arrayAdapter1.addObject(ogres[0]);
        arrayAdapter1.addObject(ogres[1]);
        arrayAdapter1.addObject(ogres[2]);
        this.setContentView(R.layout.customlayout);


        ListView list11= (ListView)findViewById(R.id.list1);
        list11.setAdapter(arrayAdapter1);

    }



}


my xml file is (customlayout.xml):

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

    <ListView
               android:layout_width="fill_parent"
               android:layout_height="fill_parent"
               android:background="#FFFFFF"
               android:layout_weight="1"
               android:drawSelectorOnTop="false"/>
</LinearLayout>


the exception is: begin1Package.Landroid/widget/LinearLayout

Thanks
Sylvester
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to android-beginners@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
Announcing the new M5 SDK!
http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to