SQLite and TableView
SQLite and TableView
- Subject: SQLite and TableView
- From: Sanri Parov <email@hidden>
- Date: Tue, 15 Jul 2003 00:44:59 +0200
Hi everybody,
since I'm fairly new to delegation system, I'll ask your help to return
the results of a query from SQLDatabase wrapper for SQLite to an
NSTableView.
Let's say my database is very simple: the records are 'name' and 'age'
(TEXT and INTEGER).
I know I have to implement these two protocols
- (int)numberOfRowsInTableView:(NSTableView *)aTableView{}
- (id)tableView:(NSTableView *)aTableView
objectValueForTableColumn:(NSTableColumn *)aTableColumn
row:(int)rowIndex{}
In the first case it's very simple to get the number of the rows from
my database, but the second one leaves me with some doubts:
1) How to populate in the simplest way the table?
2) Must I transform the return query values to an NSMutableArray?
3) When and how must I redraw the TableView? As far as it's into a
drawer, before or after the drawer is opened?
Thank you very much for any answer! :-))
--
Sanri Parov
_______________________________________________
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.