--[[ @desc: 计算字符串字符个数 author:{author} time:-- :: --@inputstr: 源字符串 return 字符个数 ]] function getStringCharCount(str) local lenInByte = #str local charCount = local i = while (i <= lenInByte) do local curByte = string.byte(str, i) local byteCount = ; an
delphi 简单的删除字符串尾部数字的代码 方式一: function FilterShowName(const sName: String): String; var I: Integer; begin Result := sName; if Result <> '' then begin do begin ', '-'] then Delete(Result, I, ) else Break; end; end; end; 方式二(未测试): function GetChinese(S