NewGuid()的使用,NewGuid()使用
分享于 点击 41884 次 点评:254
NewGuid()的使用,NewGuid()使用
string str = System.Guid.NewGuid().ToString("N") + "|"+ System.Guid.NewGuid().ToString("D") + "|"
+ System.Guid.NewGuid().ToString("B") + "|"
+ System.Guid.NewGuid().ToString("P");
Response.Write(str);
说明符 返回值的格式
N 32 位:
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
D 由连字符分隔的 32 位数字:
xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
B 括在大括号中、由连字符分隔的 32 位数字:
{xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}
P 括在圆括号中、由连字符分隔的 32 位数字:
(xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)
相关文章
- 暂无相关文章
用户点评