3.0 beta 2

Question about adding a new row and refresh the table.

I want to add some new rows to the table. After that the table has to be refreshed. How can I do it.

Right now, the data is storing as a array:

myData = [ [] , [] ];
....
obj.setDataProperty("text", function(i, j){return myData[i][j]});

How can I add a new row and refresh after that?

Thanks,
flashsnake
May 3,
Please look at /examples/new/add delete row.htm
Alex (ActiveWidgets)
May 3,
Assign ur values to a new Array
var myTempData= new Array();
for(var arrayIndex=0;arrayIndex<indexlength;arrayIndex++)
{
myTempData[arrayIndex][1]=78;
myTempData[arrayIndex][2]=45;
}

Assign the new Array to ur Grid data and refresh it. Works 4 me!!
top.opener.top.myData = myTempData;
top.opener.top.content.cobj.setSelectionProperty("index", -1);
top.opener.top.content.cobj.setRowProperty("count",myTempData.length);	
top.opener.top.content.cobj.setEvent("onclick",function(){});
top.opener.top.content.cobj.refresh();
Dhivya Suresh
July 7,
Thanks for your comment. One problem is the sorting doesn't run correctly. Some of the columns (not all) are not in correct order. Do you have idea?
flashsnake
July 7,
I have a javascript error on my grid when I refresh the table after sorting any column.
flashsnake
July 31,
Find the solution by adding

--> obj.setRowProperty("value", function(i){return i});
obj.refresh();

Cheers

flashsnake
August 1,

This topic is archived.

See also:


Back to support forum

Search

Version 2

Looking for AW 2.6 ?
The old site is here.