2011年01月17日 過去Blog
– (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { static NSString *CellIdentifier = @”Cell”; UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier]; if (cell == nil) { cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease]; } //ref of Addressbook ABAddressBookRef book = ABAddressBookCreate(); //Count of Addressbook //CFIndex cnt = ABAddressBookGetPersonCount(book); //NSLog(@”addressbook count is %d “,cnt); //AllRecords of Addressbook CFArrayRef records = ABAddressBookCopyArrayOfAllPeople(book); //record at index=i ABRecordRef person = CFArrayGetValueAtIndex(records,indexPath.row); NSString *firstName = (NSString *)ABRecordCopyValue(person, kABPersonFirstNameProperty); NSString *lastName = (NSString *)ABRecordCopyValue(person, kABPersonLastNameProperty); if (firstName == nil) { firstName = @””; } if (lastName == nil) { lastName = @””; } cell.textLabel.text = [NSString stringWithFormat:@”%@ %@”,lastName,firstName]; return cell; }

この投稿へのコメント

コメントはまだありません。

コメントを残す

メールアドレスが公開されることはありません。

次のHTML タグと属性が使えます。
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

CAPTCHA


ピックアップ記事

オーガナイザーからProvisioningする際にエラー

2010年12月23日 過去Blog
新しく購入したipadをオーガナイザーから、Provisioningしようとすると以下のようなエラーが出ました。 An unexpected error occurred. Please try again. If the problem persists, please contact Apple Developer Support. mac上のXCodeがiOS4.1のバージョンだったため、…
「オーガナイザーからProvisioningする際にエラー」をはてなブックマークに追加

AVIファイルからSWF作成 MotionSWF

2010年10月07日 過去Blog
AVIからSWFファイルに変換する際に便利なソフト MotionSWF http://www.vector.co.jp/soft/dl/win95/art/se226046.html vps…
「AVIファイルからSWF作成 MotionSWF」をはてなブックマークに追加

UIImageViewに画像を配置する

2010年12月17日 過去Blog
IBOutlet UIImageView *bgImage; @property(nonatomic,retain) IBOutlet UIImageView *bgImage; 上記のようなbgImageがInterfaceで宣言され、Interface Builder上に、UIImageViewが配置されているとすると以下のように実装すれば、該当箇所に画像が挿入されます。 bgImage.…
「UIImageViewに画像を配置する」をはてなブックマークに追加

超簡単にキャベツの臭みをとる!

2010年07月22日 過去Blog
超簡単にキャベツの臭みをとる!
WEBとは全然関係ない話題ですが、お店などで出てくる生のキャベツは臭みもなく美味しく食べれるのですが、生のキャベツを家庭で食べようとすると、どうしても臭みがあるので、どうしたものかと調べていると簡単に解決出来る方法がありましたので、メモしておこうと思います。 方法は本当に簡単で、、、、、 「冷水にさらす」 ・・・以上で簡単にキャベツの臭みがなくなりました。 以下のサイトには…
「超簡単にキャベツの臭みをとる!」をはてなブックマークに追加

iPadでiOS Dev Center内のリファレンスを見ると(^^)

2011年01月08日 過去Blog
iPad用に最適化されていて、とても使いやすくなっています(^_^) 私は、さっき気付いたんですが、既にご存知の方も多いのかもしれませんが、、、(^_^;)…
「iPadでiOS Dev Center内のリファレンスを見ると(^^)」をはてなブックマークに追加
© graffiti on the web . All rights reserved. WordPress Theme by comfy