XML data based grid change row background if one of the value matches the condtion
Hi,
I got the active widgets grid and the XML is used to display the data in the grid
// create ActiveWidgets data model - XML-based table
var table1 = new AW.XML.Table;
// specify rows XPath
table1.setRows("//iSites/submissions");
var myColumns1 = ["@val0","@val1","@val2", "@val3", "@val4"];
table1.setColumns(myColumns1);
var obj = new AW.Grid.Extended;
obj.setSelectionMode("single-row");
obj.setId("myGrid1");
obj.setColumnCount(5);
var value = obj.getRowPosition();
obj.setRowPosition(value);
var myHeaders = ["Col0","Col1","Col2","Col3", "Col4"];
obj.setHeaderText(myHeaders);
var celvalue = obj.getCurrentRow();
alert(celvalue);
obj.setSelectorVisible(true);
obj.setSelectorWidth(30);
obj.setSelectorText(function(i){return this.getRowPosition(i)+1});
obj.setControlSize(699, 625);
obj.setCellModel(table1);
table1.response(xml);
in this i wanted to check if the particular val3 = 432 then the background should be red for that row..
Can anyone please let me know how do i achieve that
I got the active widgets grid and the XML is used to display the data in the grid
// create ActiveWidgets data model - XML-based table
var table1 = new AW.XML.Table;
// specify rows XPath
table1.setRows("//iSites/submissions");
var myColumns1 = ["@val0","@val1","@val2", "@val3", "@val4"];
table1.setColumns(myColumns1);
var obj = new AW.Grid.Extended;
obj.setSelectionMode("single-row");
obj.setId("myGrid1");
obj.setColumnCount(5);
var value = obj.getRowPosition();
obj.setRowPosition(value);
var myHeaders = ["Col0","Col1","Col2","Col3", "Col4"];
obj.setHeaderText(myHeaders);
var celvalue = obj.getCurrentRow();
alert(celvalue);
obj.setSelectorVisible(true);
obj.setSelectorWidth(30);
obj.setSelectorText(function(i){return this.getRowPosition(i)+1});
obj.setControlSize(699, 625);
obj.setCellModel(table1);
table1.response(xml);
in this i wanted to check if the particular val3 = 432 then the background should be red for that row..
Can anyone please let me know how do i achieve that
Vijay
January 18,