//script.AppendLine(" var maxrow= grid.Rows.length; ");
//script.AppendLine(" for( var i=0; i<maxrow; i++) ");
//script.AppendLine(" { ");
//script.AppendLine(" grid.Rows.getRow(i).setSelected(); ");
////script.AppendLine(" grid.Rows.remove( grid.Rows.getRows(i).Element.id , false); ");
////script.AppendLine(" grid.Rows.activate(); ");
////script.AppendLine(" grid.Rows.deleteRow(); "); //igtbl_deleteSelRows("UltraWebGrid1");
////script.AppendLine(String.Format("igtbl_deleteSelRows(\"{0}\");", this.igGrid_BusorReg.ClientID));
//script.AppendLine(" } ");
출력된 로우줄을 구하여
모든줄을 (선택한 로우를) active시키고
선택한 로우 지우기
하지만 이렇게 하니 postback가 일어난다 제길;
script.AppendLine("var grid = " + String.Format("igtbl_getGridById(\"{0}\");", this.igGrid_BusorReg.ClientID));
script.AppendLine("var rows = " + String.Format("igtbl_getRowById(\"{0}\");", this.igGrid_BusorReg.ClientID));
// 출력된 그리드 Row 삭제처리
script.AppendLine(" var maxrow= grid.Rows.length; ");
script.AppendLine(" for( var i=0; i<maxrow; i++) ");
script.AppendLine(" { ");
script.AppendLine(" grid.Rows.remove(0);");
script.AppendLine(" } ");
수정하였다.
row객체를 날려버린다 ㅎ
Rows
The rows collection object.
Rows Methods
addNew |
Adds a new row to the collection. Returns
Object. The row object that was added. Null if adding a new row has failed. |
getColumn |
Gets the header HTML element for a specified column index. Parameters colNo
Number. The index of the column to return the header element for. Returns
Object. The HTML element of the requested header. Null if no header with such index is found. |
getFilterRow |
Returns the FilterRow object for this Rows collection. |
getFooterText |
Gets the footer text. Parameters columnKey
String. The column's key to get the footer text from. Returns
String. The column's footer text. |
getRow |
Gets a row from the rows collection. The method has to be use to retrieve rows from the rows collection. Parameters index
The row index to retrieve. Returns
Object. The row object requested by the index. Null if no row existed with specified index. |
getRowById |
Returns a row object based on it's id. Parameters rowId
The id of the row that is trying to be found. |
hasRowFilters |
Indicates if the rows collection has any filters applied to it. Returns
Boolean. True if filters are applied. |
indexOf |
Gets index of a specified row. Parameters row
Object. The row object to get index of. Returns
Number. The row index. -1 if no such row is found in the collection. |
insert |
Inserts previously removed row to the collection. Insert is supported for the rows that were removed from the same collection only. Parameters row
Object. The row object to insert. rowNoNumber. The new row index to insert to. Returns
Boolean. True if insertion succeeded. |
reapplyRowStyles |
When called the Grid will process the rows and reapply styles. This is useful when doing sorting or other operations which may cause alternate styles and normal row styles from getting out of sync. |
refresh |
Sends an AJAX request back to the server to refresh the rows collection. Can be called only when LaodOnDemand is set to Xml. Does nothing with any other setting of the property. Please note that for the top rows collection the grid will return to its initial RowsRange number of rows. Also the rows selection is not preserved, as well as all expanded child rows are collapsed. |
remove |
Removes a row from the collection. Parameters rowNo
Number. The row's index to remove. fireEventsBoolean. Optional. Indicates if events should be fired. Events are fired by default. Returns
Object. The removed row object. |
setFooterText |
Sets a column's footer text for the collection only. To set all footers of the column use the Column.setFooterText method. Parameters columnKey
String. The column's key to set the footer text to. valueString. The text to set on the column's footer. useMaskBoolean. Optional. If true the value is converted to the column's data type and the column's mask is applied to it. |
sort |
Sorts the collection according to the band's sorted columns collection |
sortXml |
Sorts the collection using XML renderer. The procedure is done using XmlHTTP request back to the server and new sorted rows set substitutes the existing one. |
Rows Properties
AddNewRow |
Object. Reference to the add new row object if it exists in the rows collection. See description of the object below. |
Band |
Object. The band reference. |
Element |
Object. The HTML element associated with the rows collection. |
Grid |
Object. The grid reference. |
Id |
String. The rows collection Id. |
length |
The length of the client side rows collection. |
Node |
Object. The XML node associated with the rows object if the XML rendering is enabled. |
ParentRow |
Object. The reference to this rows collection's parent row, or null if this is the top rows collection. |
Type |
String. Type of the client side object. That is "rows" for the rows object. |