Datagrid refresh
Posted: Tue May 26, 2009 7:59 am
Hello all!
In the datagrid user guide PDF and the Lessons, it's noted that you should not attempt to refresh the grid from a control inside the grid. If my understanding is correct, this is because Rev is trying to delete the very control that is calling the refresh. Yes?
Ok, so... how does one get around this? In the solution I'm building, I absolutely have to be able to refresh the grid when the contents of a line change, when a new line is inserted or one is deleted.
A basic description of my grid is this:
it is an SQL-stored, datagrid-viewed event log of user-entered events on a given day (the user navigates which day to display elsewhere on the main stack). All lines have a timestamp field and various other fields about the event entry. Each line also displays the time interval between itself and the previous line. In the case of the first line, the interval is between that line and the last line of the previous day. This calculation is done by SQL and not by Rev. This interval calculation is "mission-critical" and thus MUST be accurate at all times. Each line contains a "deleteLine" button, may contain one of a variety of "postThisEdit" controls, but adding a record is handled outside the grid, and I can handle updating the grid for that process.
So, in the cases of deleteing or changing a line, the thread at:
http://forums.runrev.com/phpBB2/viewtopic.php?t=3056 might contain the answer but I wanted to be sure that was the right way to go before I go implementing anything.
Your help greatly appreciated...
In the datagrid user guide PDF and the Lessons, it's noted that you should not attempt to refresh the grid from a control inside the grid. If my understanding is correct, this is because Rev is trying to delete the very control that is calling the refresh. Yes?
Ok, so... how does one get around this? In the solution I'm building, I absolutely have to be able to refresh the grid when the contents of a line change, when a new line is inserted or one is deleted.
A basic description of my grid is this:
it is an SQL-stored, datagrid-viewed event log of user-entered events on a given day (the user navigates which day to display elsewhere on the main stack). All lines have a timestamp field and various other fields about the event entry. Each line also displays the time interval between itself and the previous line. In the case of the first line, the interval is between that line and the last line of the previous day. This calculation is done by SQL and not by Rev. This interval calculation is "mission-critical" and thus MUST be accurate at all times. Each line contains a "deleteLine" button, may contain one of a variety of "postThisEdit" controls, but adding a record is handled outside the grid, and I can handle updating the grid for that process.
So, in the cases of deleteing or changing a line, the thread at:
http://forums.runrev.com/phpBB2/viewtopic.php?t=3056 might contain the answer but I wanted to be sure that was the right way to go before I go implementing anything.
Your help greatly appreciated...