setCurrencyCode:
現在のコードをセットします
-(void)setCurrencyCode:(NSString *)string:
- 作者: Source Wikipedia,LLC Books,Books Group
- 出版社/メーカー: Books LLC, Wiki Series
- 発売日: 2011/06/25
- メディア: ペーパーバック
- この商品を含むブログを見る
解説
現在のコードをセットします。
フォーマッターの挙動を NSNumberFormatterBehavior10_4 にしておかなければ機能しません。
コードは ISO 4217を参照。
返り値
( void )
なし
引数
( NSString * )string
フレームワーク
Foundation
クラス
NSNumberFormatter
Instance Methods
使用可能
10.4
参照
-currencyCode
例文
- (IBAction)myAction:(id)sender { NSNumberFormatter *numFormat = [[[NSNumberFormatter alloc] init] autorelease] ; [numFormat setFormatterBehavior: NSNumberFormatterBehavior10_4 ]; [numFormat setCurrencyCode:@"AUD"]; NSLog(@"currencyCode %@",[numFormat currencyCode]); }