本文整理自网络,侵删。
function RollStr(str: string; count: Integer = 1): string;
var
i, k, len: Integer;
begin
len := length(str);
for k := 0 to Count - 1 do
begin
if ord(str[1]) > 127 then
str := copy(str, 3, MAXINT) + copy(str, 1, 2)
else
str := copy(str, 2, MAXINT) + copy(str, 1, 1);
end;
Result := str;
end;
procedure TForm1.Timer1Timer(Sender: TObject);
begin
caption := RollStr(caption);
end;
相关阅读 >>
Delphi 错误no ftp list parsers have been registered
Delphi 判断两个时间差是否在一个指定范围内 -withinpastyears、withinpastmonths、withinpastweeks、withinpastdays
Delphi运行时的问题,cannot focus a disabled or invisible window!
更多相关阅读请进入《Delphi》频道 >>