Shoaib Dar wrote:
>
> I want a RelativeLayout that's composed of two parts: The bottom portion 
> is an xml TableLayout file, and the top portion, which i plan to do later, 
> will be a separate custom view. 
> So far i [sic] tried to add the TableLayout to the RelativeLayout and am 
> already getting an error.
>

*What* error?

Incomplete data yield incomplete answers.

Consider following the advice at http://sscce.org/
 

> public class mainActivity extends Activity{
>
>
Type names should start with an upper-case letter, by convention.
 

> RelativeLayout relativeLayout;
> TableLayout tableLayoutl;
>
>
What is 'tableLayoutl' used for?
 

> @Override
> protected void onCreate(Bundle savedInstanceState) {
> super.onCreate(savedInstanceState);
> relativeLayout=new RelativeLayout(this);
> ViewGroup vg= (ViewGroup)findViewById(R.layout.myTableLayout);
> RelativeLayout.LayoutParams relativeParams = new 
> RelativeLayout.LayoutParams(LayoutParams.FILL_PARENT, 
> LayoutParams.FILL_PARENT);
>
>
You don't show your imports. Did you import 'LayoutParams'?

relativeLayout.addView(vg,relativeParams);
> setContentView(relativeLayout);
>  }
> }
>
> I feel like there is a much easier way to do this, any help? 
>

Based on what do you feel that?

-- 
Lew
 

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to