hi , I am trying to set the ui component in follwoing manner but screen is empty .. Here is the code 1)The Activity class public class TermsScreen extends Activity implements View.OnClickListener {
@Override public void onCreate(Bundle bundle) { super.onCreate(bundle); s); DemoScreen obj = new DemoScreen(this); setContentView(obj); } 2) Demoscreen class public class DemoScreen extends LinearLayout { public DemoScreen(Context context) { super(context); StringItem strItem = new StringItem(context,"End User Agreement","All Right Reserved by Umundo Inc."); TextItem txtItem = new TextItem(context,"User Name"); } } 3) TextItem class & StringItem are functionally same class public class TextItem extends LinearLayout { public EditText m_editText ; public TextView m_textView ; public TextItem (Context context,String lable) { super(context); setOrientation(VERTICAL); LinearLayout.LayoutParams layoutParams = new LinearLayout.LayoutParams(-1,LayoutParams.WRAP_CONTENT); layoutParams.setMargins(1,1, 1,1); m_editText = new EditText(context); m_editText.setGravity(Gravity.CENTER_VERTICAL); m_textView = new TextView(context); m_textView.setText(lable); m_textView.setTextSize(17f); m_textView.setTextColor(Color.CYAN); m_editText.setHeight(5); addView(m_textView,layoutParams); addView(m_editText,layoutParams); } } when i am set TextItem & StringItem directly in activity class then only one ui component is displayed on screen . but i want add both at a same time . please help me. Thanks in advance. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---