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


ピックアップ記事

サーバの時刻調整

2010年03月05日 過去Blog
サーバの時刻設定 1. 時刻確認 date 2. 時刻設定 date -s "2006/02/20 19:03" linux上で、上記のコマンドを実行すれば、調整出来ます。 参照元:http://memorva.jp/memo/linux/date_ntp.php buy anabolics online…
「サーバの時刻調整」をはてなブックマークに追加

PHP session 破棄

2010年06月11日 過去Blog
PHPでセッションを完全に破棄する <?php // セッション変数を全て解除する $_SESSION = array(); // セッションを切断するにはセッションクッキーも削除する。 // Note: セッション情報だけでなくセッションを破壊する。 if (isset($_COOKIE[session_name()])) { setcookie(session_name(),…
「PHP session 破棄」をはてなブックマークに追加

Hello world!

2011年05月10日 過去Blog
WordPress へようこそ。これは最初の投稿です。編集もしくは削除してブログを始めてください !
「Hello world!」をはてなブックマークに追加

[12] 再生中の曲情報を取得・表示させる

2010年12月21日 過去Blog
今回のチュートリアルは、ipod(iphone&ipad未検証)のミュージックプレイヤーで再生中の曲の情報を取り出して、表示させる方法を説明します。 …
「[12] 再生中の曲情報を取得・表示させる」をはてなブックマークに追加

Linux ユーザー一覧の確認

2010年02月02日 過去Blog
[hogehoge@localhost ~]$ cat /etc/passwd http://kazmax.zpp.jp/lin/etc_passwd.html is garcinia cambogia safe to take…
「Linux ユーザー一覧の確認」をはてなブックマークに追加
© graffiti on the web . All rights reserved. WordPress Theme by comfy