:: Forum >>

Adding dynamic data

Hi All...

I'm reading the ActiveWidgets documentation, it's a great widget!!.
I think I didn't find the way to add data with JavaScript once the array was loaded to the widget....

My question is, Can I add data in a dynamic form I mean something like to take a value of an input and then put that value in the grid....
Another form may be the grid editable so the user can add a new row and edit that row...

Thanks!
Matutek
Thursday, May 26, 2005
All you need to do is make the appropriate changes to the Javascript array that the data is in, then call refresh() on the grid. If you add rows to the array then you will also have to make a change to setRowCount before calling refresh. Same is true is you add columns, do a setColumnCount() prior to calling refresh().
Remember that the grid is a visual representation of the data, the data is still the array. Any change to the array will be reflected in the grid once you call refresh().
Jim Hunter
Friday, May 27, 2005
Doing this doesn't reset the highlighted row (if you're adding additional rows), but the scrollbar resets to the top of the page...With a quick search, I can't see how to set the position of the scroll bar, but I'll take a deeper look.
Craig Jones
Wednesday, June 1, 2005
Do a quick search on this Forum for ScrollIntoView, this is a nifty way to get the scrollbars and the highlighted row back into sync after data changes.
Jim Hunter
Wednesday, June 1, 2005

This topic is archived.


Back to support forum

Forum search