简体   繁体   English

如何使用C#检测正在进行的下载?

[英]how do I detect download in progress using c#?

如何使用c#检测进行中的下载(在任何应用程序中,例如IE或firefox或下载管理器中的下载)?

恕我直言,这几乎是不可能的。

The best you could hope for is some sort of packet monitor that ties the packets to a particular process ID. 您可能希望的最好的办法是将数据包与特定进程ID绑定在一起的某种数据包监视器。 Even given that, you wouldn't be very well able to track an individual download, but rather the entire throughput of a single process (each packet of data coming in or out). 即使这样,您也无法很好地跟踪单个下载,而无法跟踪单个进程的整个吞吐量(每个数据包进出)。

Using HTTPAnalyzer, you should be able to infer this to certain extent - but this will be a manual process. 使用HTTPAnalyzer,您应该能够在一定程度上进行推断-但这将是一个手动过程。 May be u can use some some of its exposed API to automate. 也许您可以使用其某些公开的API来实现自动化。
BTW why do you need this - is there a practical scenario where this is really required? 顺便说一句,为什么您需要这样做-是否有实际需要的实际情况?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何使用 ProgressBar、Progress 和 IProgress 显示任务的进度<int> C#</int> - How do I display the progress of a Task using ProgressBar, Progress, and IProgress<int> C# 如何使用c#从LiveLink下载文件? - How do I download a file from LiveLink using c#? 如何使用WebClient在C#中下载文件? - how do I download a file in c# using webclient? 如何使用winforms从网上下载显示下载进度的图像? - How to download an image from web showing the progress of the download in c# using winforms? 如何减少使用 ReadCommitted 事务的 Progress OpenEdge OdbcCommand 报告 C# 中的锁定所需的时间? - How do I decrease the time it takes for a Progress OpenEdge OdbcCommand using ReadCommitted transaction to report a lock in C#? 我如何在 C# 中获得为“MediaToolKit”工作的进度条? - How Do I Get A Progress Bar Working for "MediaToolKit" in C#? C#如何实现进度条? - How do I implement a progress bar in C#? 如何在C#中跟踪Powershell的进度和错误? - How do I track a Powershell progress and errors in C#? 使用带有进度条的WININET功能在C#中进行FTP上传/下载 - FTP Upload/Download in C# using WININET functions with progress bar 如何在进度栏中显示图像加载进度c# - How Do I Show Image Loading Progress in progress-bar c#
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM