login about faq


Using VC2013 and the latest libraries. I have this code:

CMyFtpTransferZipProgress ftpProgress(&m_wndStatusBar, strTarget); ftp.put_EventCallbackObject(&ftpProgress);

I updated CMyFtpTransferZipProgress to inherit from CkFtp2Progress and did a full rebuild but I still get an error:

4>MainFrm.cpp(2773): error C2664: 'void CkFtp2W::put_EventCallbackObject(CkFtp2ProgressW )' : cannot convert argument 1 from 'CMyFtpTransferZipProgress ' to 'CkFtp2ProgressW *'

I have followed:




asked Apr 29 '14 at 09:01

Andrew's gravatar image


edited Apr 29 '14 at 10:07

If using the wide-char version of the Chilkat class (i.e. the one ending with a "W", such as CkFtp2W), then use the wide-char version of the event callback class.

You'll find it in the CkFtp2ProgressW.h header file.



To receive progress events (callbacks), create a C++ class that inherits this one and provides one or more overriding implementations for the events you wish to receive.


// When creating an application class that inherits the CkFtp2ProgressW base class, use the CK_FTP2PROGRESSW_API // definition to declare the overrides in the class header. This has the effect that if for // some unforeseen and unlikely reason the Chilkat event callback API changes, or if new // callback methods are added in a future version, then you'll discover them at compile time // after updating to the new Chilkat version.
// For example: /* class MyProgress : public CkFtp2ProgressW { public: CK_FTP2PROGRESSW_API


/ #define CK_FTP2PROGRESSW_API void BeginDownloadFile(const wchar_t pathUtf8, bool skip); void EndDownloadFile(const wchar_t pathUtf8, int64 numBytes); void VerifyDownloadDir(const wchar_t pathUtf8, bool skip); void BeginUploadFile(const wchar_t pathUtf8, bool skip); void EndUploadFile(const wchar_t *pathUtf8, int64 numBytes); void VerifyUploadDir(const wchar_t pathUtf8, bool skip); void VerifyDeleteDir(const wchar_t pathUtf8, bool skip); void VerifyDeleteFile(const wchar_t pathUtf8, bool skip); void UploadRate(int64 byteCount, unsigned long bytesPerSec); void DownloadRate(int64 byteCount, unsigned long bytesPerSec);


answered Apr 29 '14 at 10:35

chilkat's gravatar image

chilkat ♦♦

edited Apr 29 '14 at 10:36

Thank you. :)

(Apr 29 '14 at 17:04) Andrew
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or __italic__
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported



Asked: Apr 29 '14 at 09:01

Seen: 636 times

Last updated: Apr 29 '14 at 17:04

powered by OSQA