【发布时间】:2011-12-06 16:12:28
【问题描述】:
我想将长路径截断为特定长度。但是,我想在中间加上省略号。
例如:\\my\long\path\is\really\long\and\it\needs\to\be\truncated
应该变成(截断为 35 个字符):\\my\long\path\is...to\be\truncated
是否有可用的标准函数或扩展方法?
【问题讨论】:
-
这在stackoverflow.com/questions/8360360/…也得到了很好的回答
标签: c#