Свойство | Тип | Описание | |
---|---|---|---|
DownloadedBytes | long | ||
Percent | float | ||
Progressbar | System.Windows.Forms.ProgressBar | ||
Speed | long | ||
TotalBytes | long |
Метод | Описание | |
---|---|---|
GetCutFileName ( string url ) : string |
根据下载地址获取文件名(截尾)
|
|
GetFileName ( string url ) : string |
根据HTTP头文件并转码获取文件名
|
|
Start ( ) : void |
开始下载(如文件已存在则自动加(n))
|
|
StartWithoutThread ( ) : void | ||
Stop ( ) : void |
停止下载
|
|
TSDownload ( ) : System |
默认构造函数
|
|
TSDownload ( string url ) : System |
构造函数,下载到同目录下,保存的文件名通过url转换
|
|
TSDownload ( string url, string filename ) : System |
构造函数
|
|
removeInvChrInPath ( string origFileOrPathStr ) : string |
删除路径和文件名中的非法字符 http://www.crifan.com/files/doc/docbook/crifanlib_csharp/release/webhelp/removeinvchrinpath.html
|
|
tims_Elapsed ( object sender, System e ) : void |
Метод | Описание | |
---|---|---|
SetPbM ( int n ) : void |
修改进度条总大小
|
|
SetPbV ( int n ) : void |
修改进度条已下载大小
|
|
ThreadDL ( ) : void |
下载专用线程的方法
|
public static GetCutFileName ( string url ) : string | ||
url | string | 下载地址 |
Результат | string |
public static GetFileName ( string url ) : string | ||
url | string | 下载地址 |
Результат | string |
public TSDownload ( string url ) : System | ||
url | string | 下载地址 |
Результат | System |
public TSDownload ( string url, string filename ) : System | ||
url | string | 下载地址 |
filename | string | 保存的文件名(可包含绝对路径) |
Результат | System |
public static removeInvChrInPath ( string origFileOrPathStr ) : string | ||
origFileOrPathStr | string | |
Результат | string |
public tims_Elapsed ( object sender, System e ) : void | ||
sender | object | |
e | System | |
Результат | void |
public ProgressBar,System.Windows.Forms Progressbar | ||
Результат | System.Windows.Forms.ProgressBar |