sprintf(sMsg,"Upload failed (%s)",CkSFtp_lastErrorText(hSftp));
when using this all I get as output is
upload failed (Chilkat log:
but no actual text, as if there are 0 characters in the error string.
The LastErrorText will contain multiple lines, with CRLF line endings. My guess is that you're only displaying the 1st line.