Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum

View Single Post
Old 07-07-2011, 05:44 AM   #7 (permalink)
epita
msm
 
Join Date: Jul 2011
Posts: 3
epita is on a distinguished road
Default ipod access library

i tried to read the apple doc but ended up into many errors:
heres what i did

Following is what i have done so far:

MPMediaQuery *media_artsist = [[MPMediaQuery alloc] init];
[media_artsist setGroupingType: MPMediaGroupingArtist];
collections = [media_artsist collections];

So when i log
NSLog(@"-------- %@",collections);

i get:
(
"<MPConcreteMediaItemCollection: 0x2de330>",
"<MPConcreteMediaItemCollection: 0x2de5b0>",
"<MPConcreteMediaItemCollection: 0x2de1a0>",
"<MPConcreteMediaItemCollection: 0x2de750>"
)


But when i try to display it on tableview i get a error:

- (UITableViewCell *)tableViewUITableView *)tableView cellForRowAtIndexPathNSIndexPath *)indexPath {

static NSString *MyIdentifier = @"MyIdentifier";
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:MyIdentifier];
if (cell == nil) {
cell = [[[UITableViewCell alloc] initWithFrame:CGRectMake(0,0,0,0) reuseIdentifier:MyIdentifier] autorelease];
cell.selectionStyle = UITableViewCellSelectionStyleNone;
cell.accessoryType = UITableViewCellAccessoryCheckmark;

cell.textLabel.text =[collections objectAtIndex:indexPath.row]; //objectForKey:@"title"]; //

}
return cell;

}


error is:
2011-07-07 10:38:50.242 FSDSClient[1033:707] -[MPConcreteMediaItemCollection isEqualToString:]: unrecognized selector sent to instance 0x2e2c30
2011-07-07 10:38:50.294 FSDSClient[1033:707] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[MPConcreteMediaItemCollection isEqualToString:]: unrecognized selector sent to instance 0x2e2c30'
terminate called after throwing an instance of 'NSException'
epita is offline   Reply With Quote
 

» Advertisements
» Online Users: 383
14 members and 369 guests
Absentia, alisafl22, bbbsaha, DaveDee, erdinc27, fredidf, Hercule, heshiming, Johnsyfared, milanalina, prbiztech, roof44, waghman, wserver
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,603
Threads: 94,084
Posts: 402,782
Top Poster: BrianSlick (7,990)
Welcome to our newest member, alisafl22
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 03:59 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.