androiduser
androiduser

Reputation: 977

How to display a TableLayout with different column sizes in different rows in android programatically

Hi guys iam working with a screen with includes a TableLayout .In my TableLayout i would like to diplay several rows with different column sizes, and also i would like to give padding to certain rows to display buttons in specific columns programatically.

Suppose in the First row i would like to display each TextView with a width of "90dip"

In the Second row i would like to display a TextView with "360dip".And at the same time i would like to give some padding to the left of the TableRow let it be "100dip",and from that i want to display the TextView with "360dip".

Any Suggestions.

Upvotes: 0

Views: 1101

Answers (2)

einschnaehkeee
einschnaehkeee

Reputation: 1888

Here is a possible answer and how I like to use the tabhost: http://einschnaehkeee.blogspot.com/2011/10/how-to-tame-android-tabhost.html

In short: get rid of the TabWidget and use the TabHost with your own UI, it's so much better and more flexible. :-)

Upvotes: 0

clemp6r
clemp6r

Reputation: 3723

Well according to your example you should use a LinearLayout and not a TableLayout.

Upvotes: 1

Related Questions