You could also use the windows API function: void _splitpath(const char *path, char *drive, char *dir, char *fname, char *ext) in <stdlib.h>. For (my) convenience I use this in a C++ wrapper and return std::string values. One also needs to use the char *_getcwd(char *buffer, int maxlen) if you...
I don't see a LeftStr() mentionned in the list of methods for AnsiString nor is LeftStr() in the Borland C++ Help Index. The closest function I can think of is "AnsiString __fastcall SubString(int index, int count) const;"
IMHO stringstream provides an easy and typesafe way to convert anything to strings:
std::stringstream ss ;
ss << scientific << 5.3*sin(1.23456) ;
cout "The answer is " << ss.str() << endl ;
Have a look at this article...