DownloadProgressChangedEventHandler デリゲートとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > DownloadProgressChangedEventHandler デリゲートの意味・解説 

DownloadProgressChangedEventHandler デリゲート

メモ : このデリゲートは、.NET Framework version 2.0新しく追加されたものです。

WebClient の WebClient.DownloadProgressChanged イベント処理するメソッド表します

名前空間: System.Net
アセンブリ: System (system.dll 内)
構文構文

Public Delegate Sub DownloadProgressChangedEventHandler
 ( _
    sender As Object, _
    e As DownloadProgressChangedEventArgs _
)
Dim instance As New DownloadProgressChangedEventHandler(AddressOf
 HandlerMethod)
public delegate void DownloadProgressChangedEventHandler
 (
    Object sender,
    DownloadProgressChangedEventArgs e
)
public delegate void DownloadProgressChangedEventHandler
 (
    Object^ sender, 
    DownloadProgressChangedEventArgs^ e
)
/** @delegate */
public delegate void DownloadProgressChangedEventHandler
 (
    Object sender, 
    DownloadProgressChangedEventArgs e
)
JScript では、デリゲート使用できますが、新規に宣言することはできません。

パラメータ

sender

イベントソース

e

イベント データ格納している DownloadProgressChangedEventArgs。

解説解説
使用例使用例

WebClient.DownloadProgressChanged イベントイベント ハンドラ設定するコード例次に示します

'  Sample call : DownLoadFileInBackground2 ("http:' www.contoso.com/logs/January.txt")
Public Shared Sub DownLoadFileInBackground2(ByVal
 address As String)

    Dim client As WebClient = New
 WebClient()

    '  Specify that the DownloadFileCallback method gets called
    '  when the download completes.
    AddHandler client.DownloadFileCompleted, AddressOf
 DownloadFileCallback2
    '  Specify a progress notification handler.
    AddHandler client.DownloadProgressChanged, AddressOf
 DownloadProgressCallback
                Dim uri as Uri = New
 Uri(address)
    client.DownloadFileAsync(uri, "serverdata.txt")
End Sub

// Sample call : DownLoadFileInBackground2 ("http://www.contoso.com/logs/January.txt");
public static void DownLoadFileInBackground2
 (string address)
{
    WebClient client = new WebClient ();
    Uri uri = new Uri(address);

    // Specify that the DownloadFileCallback method gets called
    // when the download completes.
    client.DownloadFileCompleted += new AsyncCompletedEventHandler
 (DownloadFileCallback2);
    // Specify a progress notification handler.
    client.DownloadProgressChanged += new DownloadProgressChangedEventHandler(DownloadProgressCallback);
    client.DownloadFileAsync (uri, "serverdata.txt");
}

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照


このページでは「.NET Framework クラス ライブラリ リファレンス」からDownloadProgressChangedEventHandler デリゲートを検索した結果を表示しています。
Weblioに収録されているすべての辞書からDownloadProgressChangedEventHandler デリゲートを検索する場合は、下記のリンクをクリックしてください。
 全ての辞書からDownloadProgressChangedEventHandler デリゲート を検索

英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

「DownloadProgressChangedEventHandler デリゲート」の関連用語

DownloadProgressChangedEventHandler デリゲートのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



DownloadProgressChangedEventHandler デリゲートのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2024 Microsoft.All rights reserved.

©2024 GRAS Group, Inc.RSS