---June Kim wrote:
> Supposing there could be a multiple of grid instances at the same
> time, I made the modified celldata stored as a field instance of an
> object, so that I could keep them all separate. Moreover, I thought
> someone might want to access the value of the modified celldata while
> the grid window is still open.

I think my suggestions should handle creating multiple instances of the grid at 
once fine. However I think you are correctly suggesting that there will be a 
problem when the grids are closed (i.e the last to close will write over 
CELLDATA_ED from previously closed grids).  It would obviously be possible to 
make the naming of the noun storing the data a bit smarter so that they don't 
collide, but I'm hoping that we can get the verb to actually return the 
modified cell data so that this isn't a problem.

  newdata=: editgrid i. 4 5

However I am thinking that we perhaps have different objectives for our 
solutions. I'm after a simple way to give an array to a grid, edit it and 
return the changed grid in a J session.  I get the impression that you want to 
have more control over the what happens during editing, and are happy to manage 
the creation and destruction of the new locales as separate steps. Is your code 
going to be part of a user interface for an application?
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to