Highlight textbox text

Hi all,

I tried to put a textbox in the grid, but some reason, I cannot hightlight the text in the textbox. I have serached this forum and the reference, but I still cannot find anything related to this problem. Can anybody give me some direction?


    #grid01 {height: 200px; border: 2px inset; background: white}
    #grid01 {width: 400px; border: 2px inset; background: white}
    #grid01 .active-scroll-top, .active-scroll-corner {height: 25px}
    #grid01 .active-scroll-left, .active-scroll-data {padding-top: 25px}
    #grid01 .active-grid-column {border-right: 1px solid threedlightshadow;}
    #grid01 .active-grid-row {height: 25px}
    #grid01 .active-scroll-left .active-list-item {height: 25px}
    #grid01 .active-column-0 {width: 200px; text-align: left;}

    var myColumns01 = [ "textbox" ];
    var myData01 = [["<input type=\"text\" name=\"orderlineViewPage[0].qty\" maxlength=\"60\" size=\"10\" value=\"test text\">",]];


    //	create ActiveWidgets Grid javascript object
    var gridObj01 = new Active.Controls.Grid;
    gridObj01.setStyle("font-size", "9pt");

    //	set number of rows/columns

    gridObj01.setDataText(function(i, j){return myData01[i][j]});
    gridObj01.setColumnText(function(i){return myColumns01[i]});

    //	set click action handler
    gridObj01.setAction("click", function(src){window.status = src.getProperty("item/text")});

    var substart = 1;

    gridObj01.setRowText(function(i){return substart + i});

    var alternate = function(){
        return this.getProperty("row/order") % 2 ? "#EEEEEE" : "white";

    var row01 = new Active.Templates.Row;

    row01.setStyle("background", alternate);

    gridObj01.setTemplate("row", row01);

    //	write grid html to the page
April 13,
I just found the soluciton! So, I am answering my quesiton here.

For some reason, the highlighting is disabled in a cell. To enable it, go to the grid.js file in the libaray. Search "onselectstart" and change the value from false to ture.

April 18,

This topic is archived.

See also:

Back to support forum