SFTP OnDirectoryList compile error using BCB5
Posted: Tue  15 Mar 2011 18:22
				
				Hi! 
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:
Borland C++Builder 5 (Enterprise) won't compile the line with the function implementation: Error: E2451 Undefined symbol 'TObject'. 
My 'OnError'-event function compiles well, instead:
Any idea what is wrong? Any help how to solve? Are there any more/better examples/demos written in C++ to check? 
thanks
/gw
			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
