:: Forum >>

Unwanted text near a "Checkbox" template cell

I'have this grid:griglia_richieste.setTag("span");
                        griglia_richieste.setId("griglia_richieste");
                        griglia_richieste.setToolbar(true,"Richieste");
                        griglia_richieste.setExportFunction('ToExcelRic()');
                    
                        griglia_richieste.setStyle("position", "relative");
                        
                        griglia_richieste.setCellTemplate(new AW.Templates.CheckBox,"chiusa");
                        griglia_richieste.getCellTemplate("chiusa").setEvent("onclick", function() {});
    
                        griglia_richieste.setCellTemplate(new AW.Templates.CheckBox,"modificabile");
                        griglia_richieste.getCellTemplate("modificabile").setEvent("onclick", function() {});
    
                        var date = new AW.Formats.Date;
                        date.setDataFormat("ISO8601");
                        date.setTextFormat("dd/mm/yyyy");
                        date.setErrorText("");
                        date.setErrorValue("");
                    
                        var number = new AW.Formats.Number;
                        var string = new AW.Formats.String;
                    
                        griglia_richieste.setCellFormat({
                            progressivo:string,
                            blocco:string,
                            reparto:string,
                            data:date,
                            descrrichiesta:string,
                            note:string,
                            bloccato:string,
                            numrichiesta:string,
                            chiusa:string,
                            modificabile:string
                        });
                    
                        griglia_richieste.onRowClicked = function(event, row){
                            esegui('ricercaArticoli');
                        };
                        
                        griglia_richieste.refresh();
.

The grid showed a text near the checkboxes corresponding to the "cellData" of checkboxes' cell.

I removed that creating a new format for those cellsvar stringCheckbox = new AW.Formats.String;
stringCheckbox.dataToText = function(parData) {
return "";
}
and setting it to the cell with the checkboxes griglia_richieste.setCellFormat({
                            progressivo:string,
                            blocco:string,
                            reparto:string,
                            data:date,
                            descrrichiesta:string,
                            note:string,
                            bloccato:string,
                            numrichiesta:string,
                            chiusa:stringCheckbox,
                            modificabile:stringCheckbox
                        
});
.

There is any cleaner way to do this?
Fily84
Tuesday, August 18, 2009
You can use setCellText("", colIndex) for the checkbox columns.
Alex (ActiveWidgets)
Tuesday, August 25, 2009
It works only with numeric index or with the JSON indexed grid? Like setCellText("", "chiusa");?
Fily84
Tuesday, August 25, 2009

This topic is archived.


Back to support forum

Forum search