As Aphrodita mentioned, in Pascal,
MyChar := Copy(MyString, Length(MyString), 1)
returns the last character in MyString. If this
is not working, you may have hidden characters
which should be removed first as in:
MyChar := Copy(Trim(MyString), Length(MyString), 1)
If doing this in C/C++, remember that Pascal String
has first character at [1], not [0].