L := Length(Edit1.Text); SetLength(S, L); for I := 1 to L do S[L-I+1] := Edit1.Text[i]; Edit1.Text := S;