Re: Writing directly to NSTableView
Re: Writing directly to NSTableView
- Subject: Re: Writing directly to NSTableView
- From: Don Arbow <email@hidden>
- Date: Mon, 4 Aug 2003 09:58:20 -0700
On Saturday, August 2, 2003, at 09:16 AM, Sanri Parov wrote:
I'll explain myself better: even if a tableview it empty, by clickin'
on one of its cells, randomly, the content of the cell becomes editable
and after I've inserted something into it (by pressing TAB) a selector
does its job.
Well, you need to change the way that you think of it. Your spreadsheet
is not actually empty, but contains a bunch of cells that have no
value. So beforehand, you would define a set number of rows and
columns, then allocate the storage in your table's data source to hold
all the values.
If your spreadsheet is really large, you might want to use some sort of
sparse array to hold the values (surely there is some Cocoa code out
there for that), or you could use a dictionary with row/column
coordinate strings as keys.
Don
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.