停止使用命令行下载IDm [英] Stop Download IDm with command line

查看:422
本文介绍了停止使用命令行下载IDm的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好

我看到这个页面:http://www.internetdownloadmanager.com/support/command_line.html

但我找不到和参数停止下载

i想知道如何使用命令行参数停止下载?可能吗?



和白色此参数/ s我可以在主下载队列中开始下载!



使用命令行参数启动主下载队列!!!

 System.Diagnostics.Process.Start(@ ... \IDMan。 exe   / s  < span class =code-string>);  





现在可以启动/停止特殊队列,如果我想要怎么样?



谢谢

亲切的问候,

解决方案

请看看我对这个问题的评论。如果你不介意杀死这个过程:方法 Process.Start 将返回的实例System.Diagnostics .Process

 System.Diagnostics.Process process = System.Diagnostics.Process.Start( / *   ... * / ); 

// ...

/ / 稍后:
process.Kill();





如果你开始的是一个真正的互联网下载管理器,它肯定会停止下载:-)。

然而,这并不好;当你在中间打破它时,你不知道哪些文件只是部分下载了。



一般来说,使用进程。开始不是开发人员的方法。真正的软件开发人员将使用自己的应用程序中嵌入的下载代码,这实际上要简单得多,因为您可以完全访问功能和进度。与外部过程的情况相反:它们是完全孤立的;你无法控制它们。



请查看HttpDownloader的完整源代码,按你喜欢的方式使用它:如何从互联网上下载文件 [ ^ ]。



这个应用程序有一个特殊的功能:从同一个地方开始,以后继续不完整下载的能力。



另见我过去的答案:

FTP:下载文件 [ ^ ],

如何从中下载文件该Asp.net 2.0中的服务器 [ ^ ]。



-SA

Hello
I see this page : http://www.internetdownloadmanager.com/support/command_line.html
But i can''t find and parameter for stop download
i Want to know how can i stop download with command line parameters ? possible ?

and white this parameter "/s" i can start download in "main download queue" !

using from command line parameters for start "main download queue"!!!

System.Diagnostics.Process.Start(@...\IDMan.exe", "/s");



Now Can i start/stop a special queue , if i want ? How ?

Thanks
kind regards,

解决方案

Please see my comment to the question. If you don''t mind killing this process: the method Process.Start will return an instance of System.Diagnostics.Process:

System.Diagnostics.Process process = System.Diagnostics.Process.Start(/* ... */);

//...

//later on:
process.Kill();



If what you start is really an Internet Download Manager, it will certainly stop downloading :-).
However, this is not nice; and you won''t know which of the files was only partially downloaded as you broke it in the middle.

Generally, using Process.Start is not a developer''s approach. A real software developers will use its own downloading code embedded in your application, which is actually much simpler because you can get a full access to the functionality and progress. In contrast to the situation with external processes: they are well isolated; you cannot do much for controlling them.

Please see my full source code for HttpDownloader, use it the way you like: how to download a file from internet[^].

This application has a special feature: an ability to continue incomplete download later, starting from the same place.

See also my past answers:
FTP: Download Files[^],
how to download a file from the server in Asp.net 2.0[^].

—SA


这篇关于停止使用命令行下载IDm的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆