0

我正在尝试使用MPMediaItemCollectioncount 属性对数组中的项目进行排序。当我尝试使用此属性对数组进行排序时NSUInteger,它不起作用。当我尝试打印它 ( NSLog(@"%lx",count);) 时,它无法正确打印。

我如何才能NSUInteger正常工作?

4

2 回答 2

1

也许这会有所帮助。这适用于我使用 MPMediaCollection:

[everything setGroupingType: MPMediaGroupingGenre];
NSArray *genreLists = [everything collections];

for (MPMediaItemCollection *genreList in genreLists) {
    NSLog (@"count: %d", [genreList count]);
}
于 2009-09-17T18:23:51.140 回答
0

尝试使用以下语句:我使用它并打印出来 just find for me

NSLog(@"%d",count);

于 2009-12-16T18:19:27.523 回答