I am trying to do a loop that goes through every row & executes code. Any help would be appreciated. I have never used the infragistics, but our software uses the controls..
Use the InitializeRow event. You can get the row from e.Row. Pay attention that the event occurs when the row is initialized and also when the user change a cell value. e.Reinitialize is the difference between the two cases.
Hi,
I'm using the ultra grid.
when I load the grid with data, I have set back color of each row according to a cell value . for that I have to iterate through the grid and set the backcolor property. Is there any way that I can do the same thing without iterating the grid since it takes so much of time?
You probably just need to call the Update method on the row after you set the Value on the cell(s) in that row. Or call UpdateData on the grid after the loop completes to update all rows at once.
I use following code or similar to loop through rows
This loops throught the datasource(quicker than loop through rows in displaylayout.rows) :
For Each lineRow As Infragistics.Win.UltraWinDataSource.UltraDataRow In MyGridSet.Rows
'Code here
Next
Same code running through rows using exsisting displaylayout :
Turns out that it did not work so well. Although it was making changes at the UI, the changes did not seem to follow through to the DB. I am going to try using the DataView.