首页 > 编程知识 正文

不同地域的人有什么区别(arcgis中ascii转栅格失败)

时间:2023-05-04 17:22:26 阅读:66096 作者:845

同一DateTime.ToShortDateString ()的输出格式因地区而异

例如,美国的日期格式为月-日-年

例如在中国的日期格式是年-月-日

此格式可能会出现问题,例如编码的日期string、包含日期参数的url以及加密md5的参数。 所以需要使用CultureInfo.InvariantCulture

CultureInfo (名为InvariantCulture )类似于英语格式,但在多语言环境中提供可靠的规范格式,无论国家或地区如何

byte[XXX].tostring('x2 ',system.globalization.culture info.invariant culture );

string datestr=datetime.now.tostring (system.globalization.culture info.invariant culture;

转载于3:3359 www.cn blogs.com/J2EE-we B- 01/p/7380092.html

版权声明:该文观点仅代表作者本人。处理文章:请发送邮件至 三1五14八八95#扣扣.com 举报,一经查实,本站将立刻删除。