コード例 #1
0
        void OnDownloadProgress(string filename, int bytesTransferred, int totalBytes)
        {
            EventHandler <downloadProgressEventArgs> temp = downloadProgress;

            if (temp != null)
            {
                downloadProgressEventArgs e = new downloadProgressEventArgs();
                e.filename         = filename;
                e.bytesTransferred = bytesTransferred;
                e.totalBytes       = totalBytes;
                context.Post(delegate(object state) { downloadProgress(this, e); }, null);
            }
        }
コード例 #2
0
ファイル: MainForm.cs プロジェクト: UnDrewHa/ftpClient
 void ftpobject_downloadProgress(object sender, downloadProgressEventArgs e)
 {
     progressBar.Style = ProgressBarStyle.Marquee;
 }