Re: Supporting variable-number of table columns, based on source.
Re: Supporting variable-number of table columns, based on source.
- Subject: Re: Supporting variable-number of table columns, based on source.
- From: Kay Roepke <email@hidden>
- Date: Tue, 29 Mar 2005 20:37:11 +0200
On 29. Mar 2005, at 19:38 Uhr, Frederick C. Lee wrote:
Greetings:
I understand the basic method of populating a table, based on a model
with a given (static/constant) number of iVars that are mapped to
their respective columns of a pre-configured table structure.
But what about when you have a data source (a database table beyond
Cocoa) with an unknown number of columns?
Where can I find some documentation/example out there that shows how
to map an unknown/variable number of columns to a NSTableView?
Well, at some point you will know which columns you have, won't you?
You'll have to query your database about the column names and then set
up the columns programmatically.
See the relevant sections of NSTableView, NSTableColumn and
NSTableViewDataSource documentation for more information.
HTH,
Kay
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden