//uses ioutils
function GetValidName(s:string):string;
var
c:char;
txt:string;
begin
txt:=s;
for c in TPath.GetInvalidFileNameChars() do
begin
txt:=stringreplace(txt,c,'',[rfReplaceAll]);
end;
result:=txt;
end;
delphi 删除文件名中的非法字符
于 2023-03-26 19:17:45 首次发布