here is my 'OnDirectoryList' event function that i can't compile. The frame was autogenerated by BCB5, and i just added one line of code:
Code: Select all
void __fastcall TSftpForm::ScSFTPClientDirectoryList(TObject *Sender,
const AnsiString Path, const TBytes Handle,
TScSFTPFileInfo *FileInfo, bool EOF)
{
FilenameList->Add(FileInfo->Filename);
}
My 'OnError'-event function compiles well, instead:
Code: Select all
void __fastcall TSftpForm::ScSFTPClientError(TObject *Sender,
TScSFTPOperation Operation, const AnsiString FileName,
const TBytes Handle, int ErrorCode, const AnsiString ErrorMessage,
bool &Fail)
{
AnsiString Msg;
switch (Operation) {
case opMakingDirectory: Msg = LoadStr(FTP_MKDIR_ERROR); break;
case opRemovingFile: Msg = LoadStr(FTP_DEL_ERROR); break;
case opRemovingDirectory: Msg = LoadStr(FTP_RMDIR_ERROR); break;
case opRenamingFile: Msg = LoadStr(FTP_REN_ERROR); break;
default: Msg = ""; break;
}
if (Msg != "")
AddMessage(Msg,(TColor) FTP_MEMO_COLOR_FAILURE);
FtpError = true;
Fail = true;
}
thanks
/gw