Skip to Content

How to fix the column width in a table in htmlb tableview control

HI Experts,

I have an issue with my htmlb table view controller. I have created a custom iView with a htmlb table view control and placed it in quick navigation window.

When data in columns exceeds, I am getting horizontal scroll bar and column,table are getting extened. I don't want column size increases when text length increses. Instead when lenght of the text incrases in a column, I want the text displyed in multiple columns.

I have tried for this as below.

<hbj:tableView 
    id="statTable"
    model="bean.stattableModel"
    design="ALTERNATING"
    headerVisible="false"
    footerVisible="false"
    fillUpEmptyRows="false"
    navigationMode="BYPAGE"
    selectionMode="NONE"
    headerText="Report List"
    visibleFirstRow="1"
    visibleRowCount="10"
 width="100%">

<%
     stattableModel.getColumn("D").setWidth("5px");
     stattableModel.getColumn("D").setWrapping(false);//tried true aswell
     stattableModel.getColumn("H").setWidth("px");
     stattableModel.getColumn("H").setWrapping(false);
%>

No change happen ever after I used the above code.

Any one has the idea, how make it work.

Thanks in Advance,

Chinna.

Add a comment
10|10000 characters needed characters exceeded

Related questions

3 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Jun 25, 2009 at 05:57 AM

    Hi

    use this Defining the Layout for the First Page, might help u

    http://help.sap.com/saphelp_sm32/helpdata/en/3c/0ada085f67b14fb6fd31adbae10a94/frameset.htm

    Thanks

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jun 25, 2009 at 10:26 AM
    Add a comment
    10|10000 characters needed characters exceeded

    • Hi Prabhakaran,

      These links didn't say anything about how to fix the column width of a table.

      As said, I have tried by setting a width to a column. but it didnt work for me.

      <%

      stattableModel.getColumn("D").setWidth("5px");

      stattableModel.getColumn("D").setWrapping(false);//tried true aswell

      stattableModel.getColumn("H").setWidth("px");

      stattableModel.getColumn("H").setWrapping(false);

      %>

      Any suggestions.

      Thanks

      Chinna

  • Posted on Sep 08, 2009 at 11:40 AM

    solved myself.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.