[阅读: 265] 2006-07-04 13:36:23
Result := '';
I := 1;
sStr := ASingleStr;
while Length(sStr) <= Length(ASingleStr) do
begin
cSingle := sStr[I];
if Ord(cSingle) < 128 then
begin
Result := Result + #163 + Chr(Ord(cSingle) + 128);
Inc(I);
end
else begin
Result:= Result + Copy(ASingleStr, I, 2);
Inc(I, 2);
end;
end;