I have a grid being created from an html table. One of the columns is a link type. The column width is getting set much wider than any of the content in the any of the rows, including the header. This is subsequently forcing a horizontal scrollbar to appear for the gridbox div, which is contained in another fixed width div.
My uneducated guess is that despite the link appearing properly, the column is still formatting to the actual characters that make up the link html…?
By default grid takes width of grid columns on moment of initialization, so if width was nod defined explicitly - it may be a reason of problem.
If problem still occurs for you - please provide a snippet of HTML code from which you generating grid.
This is the html that is generating the grid, as you can see no widths have been defined. The Name column winds up being much wider than necessary.
| Total | Name |
| 400 | All^javascript:do_search(1,“all”);^_self |
| 200 | Some Data^javascript:do_search(1,2);^_self |
In case when width not set - it taken from original HTML table, in which it was wider because of url strings.
You can
a) define fixed height
<table border=“0”
class=“dhtmlxGrid” …
<td width=“100” type=“link”>Name
or
b) auto size second column
<table border=“0”
class=“dhtmlxGrid” oninit=“xgrid.adjustColumnSize(1)” …