Tuesday Oct 08, 2013

How to use to build a auto stretching table in ADF

<af:table> tag offered "width"attribute to let user adjust the width of table, but this normally is not a good option to let the table.

ADF has a default styleClass called "AFStretchWidth" which could auto adjust the table width to let it occupy the whole space.

demo code:

       <af:table
                .......
                styleClass="AFStretchWidth"
                .......
                >
        <af:column id="c1">
                   ..........
        </af:column>
      </af:table>

the table will look like

note that only the table width is stretched but the columns are not. To auto stretch the column,

attribute "columnStretching" must be applied:

  demo code:

        <af:table ......
                styleClass="AFStretchWidth"
                columnStretching="last"
                >
        <af:column id="c1">
               ......
        </af:column>
      </af:table>

the table will look like

 you can use "last" to stretch the last column, or use "first" to stretch the first column, or use "column:column-id" to specify the column you want to stretch.


About

Oracle Blogs Admin-Oracle

Search

Top Tags
Categories
Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today