Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
284
ClickCellButton CellEventArgs Not Correct
posted

Dear Infragistcs Support,

I have an unbound UltraWebGrid on an .aspx content page which utilises a Master Page. The grid has two columns of information and one column with the button data type which I intend to use as a delete button. The grid is populated by using a DataReader and manually adding the cells and rows.I want to delete rows from this table, but the UltraWebGrid does not respond in ways that I would expect.

The UltraWebGrid is within an AsyncRefreshPanel and when I click the buttons the ClickCellButton event fires on the server exactly as I would expect.

For removing a row the documentation suggests that enter the following:

e.Cell.Row.Delete

This has the effect of removing the row. However, I'm unable to read the data from the row first in order to make a SQL DELETE query to remove the row.

I have tried:

e.Cell.Row.Cells(1).Value (returns empty)

e.Cell.Row.Delete (and trying to capture the .DeleteRow event, which never fires).

However if I explicitly state: UltraWebGrid1.Rows(1).Cells(1).Value I can read the value. However e.Cell.Row.Cells(1).Value (replace the integers at will) never returns anything.

Also if I throw up a messagebox (to ask the user "Are you sure?") the grid values all simply dissapear. Is this a new bug or perhaps related? Is the server not somehow persisting the information from the client?

Please help! I just want to click a button and query the grid on the server and then repopulate the grid.

Many thanks for your time,

Mike

edit: I'm using .NETAdvantage 2008.2 in Visual Studio 2008 with a .NET 3.5 solution.