转换日期格式 年/月/日 /星期
2016-01-04 12:13
369 查看
NSDateFormatter *timeFormatter = [NSDateFormatter
new];
[timeFormatter setDateStyle:NSDateFormatterFullStyle];
NSLocale *locale = [[NSLocale
alloc] initWithLocaleIdentifier:@"zh"];
[timeFormatter setLocale:locale];
timeFormatter.dateFormat = @"yyyy/MM/dd EEE";
NSString * str= [timeFormatter
stringFromDate: NSDate * date = [NSDate
date];
];
new];
[timeFormatter setDateStyle:NSDateFormatterFullStyle];
NSLocale *locale = [[NSLocale
alloc] initWithLocaleIdentifier:@"zh"];
[timeFormatter setLocale:locale];
timeFormatter.dateFormat = @"yyyy/MM/dd EEE";
NSString * str= [timeFormatter
stringFromDate: NSDate * date = [NSDate
date];
];
相关文章推荐
- iOS开发多线程篇—多线程简单介绍
- html 灰度
- (转)IsNull和IsEmpty的区别
- 古风摄影《月华淡1》之华一
- Ubuntu 15.04下安装Apache 2.4.16
- 《Effective java》读书记录-第6条-消除过期的对象引用
- Android签名总结
- CodeForces 8D Two Friends 判断三个圆相交
- 兰州交通大学多媒体技术复习
- Kafka的环境搭建
- 撷半盏时光,叙岁月无恙。
- GC日志分析
- 关于Autoit上传文件的问题
- 【计算几何模板】求两个圆的交点
- 面向对象<2>__笔记(12)
- python 开源数据抓取框架scrapy
- C++ string 用法詳解
- mysql explain用法
- Cocos2D实现RPG队伍菜单任意调整角色顺序的效果
- Cocos2D实现RPG队伍菜单任意调整角色顺序的效果