H hansland Unregistered / Unconfirmed GUEST, unregistred user! 2005-09-21 #1 我想去掉一串字符中的所有回车符,请问应该如何处理?
H hansland Unregistered / Unconfirmed GUEST, unregistred user! 2005-09-21 #2 我想去掉一串字符中的所有回车符,请问应该如何处理?
来 来如风 Unregistered / Unconfirmed GUEST, unregistred user! 2005-09-21 #3 s := StringReplace(s,#13,'',[rfReplaceAll]); 把字符串S里的回车换了
X xiebaotong Unregistered / Unconfirmed GUEST, unregistred user! 2005-09-21 #4 var str1,str2:string;--str1你的字符串 for i:=1 to length(str1) do begin str2:=''; if (str1<>#13) and (str[1]<>#10) then str2=str2+str1; end;
var str1,str2:string;--str1你的字符串 for i:=1 to length(str1) do begin str2:=''; if (str1<>#13) and (str[1]<>#10) then str2=str2+str1; end;
差 差不多算了 Unregistered / Unconfirmed GUEST, unregistred user! 2005-11-04 #8 function TrimX(const S: string): string; var I: Integer; begin I := 1; Result := S; while (I <= Length(Result)) do begin if Result <' ' then begin Delete(Result,I,1); Dec(I); end; Inc(I); end; end;
function TrimX(const S: string): string; var I: Integer; begin I := 1; Result := S; while (I <= Length(Result)) do begin if Result <' ' then begin Delete(Result,I,1); Dec(I); end; Inc(I); end; end;