Topic: 求救 (如何把一个时间long数据转换成字符串) |
Print this page |
1.求救 (如何把一个时间long数据转换成字符串) | Copy to clipboard |
Posted by: flywithmoon Posted on: 2004-08-26 09:19 { 请尽量用准确的文字描述作为标题 } 如何把一个时间long数据转换成字符串,用下面的语句可以吗? String s=(String)(Date.getTime()); 或者是 String s=Charager.paseChar(Date.getTime()); |
2.Re:求救 [Re: flywithmoon] | Copy to clipboard |
Posted by: kam Posted on: 2004-08-26 11:08 use toString. |
3.Re:求救 (如何把一个时间long数据转换成字符串) [Re: flywithmoon] | Copy to clipboard |
Posted by: flywithmoon Posted on: 2004-08-26 13:13 是不是用法如下: String s=Date.getTime().toString(); 好像是无法通过编译 |
4.Re:求救 (如何把一个时间long数据转换成字符串) [Re: flywithmoon] | Copy to clipboard |
Posted by: jamieone Posted on: 2004-08-26 15:41 date.setTime(long~); SimpleDateFormat formater = new SimpleDateFormat("yyyy-MM-dd"); String strDateTime = formater.format(date); |
Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1 客服电话 18559299278 客服信箱 714923@qq.com 客服QQ 714923 |