用于自动Web文件下载的vb.net程序? [英] vb.net program for automatic web file download ?

查看:91
本文介绍了用于自动Web文件下载的vb.net程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,我在C#论坛上发布了以下内容但没有一个答案。

但也许现在在vb.net中有人有一些指导方针!

这是我的问题:


我想写一个vb.net程序完全自动完成什么,

直到


现在我手动做,女巫在下面描述:


1.我启动IE(6)


2.我浏览到我想要的下载页面,说
http://www.site.com/download


此下载页面包含一些文本框,复选框,

radiobuttons,下载按钮和文字


3.我检查一些复选框,选择一些radiobuttons,在一些


文本框中输入文字,然后点击下载按钮


4。我收到一个文件下载对话框


我浏览选择文件的路径/文件名


我点击保存bu tton


然后将文件保存在我的电脑上。


现在我想要一个执行以下操作的vb.net程序:


1.浏览,沉默,到我想要的下载页面

http://www.site.com/download )并填写表格


SILENTLY表示:

。没有可见的浏览页面(我不想看到下载页面


在IE中)


。 vb.net代码必须能够检查一些复选框,选择一些


radiobuttons,在某些文本框中输入文字


。填写数据后,vb.net代码必须能够点击

下载按钮


2. vb.net代码必须能够陷阱(事件) )返回的数据,总是

沉默,即


必须能够捕获文件下载对话框,填充某处


(?)路径/文件名并下载文件


希望这是可以理解的。


任何帮助,代码/文章/ HowTos ... /,欢迎。


提前谢谢你。


Jean-Marie

Hello, I posted the following in the C# forum but without one answer.
But perhaps now in vb.net someone has some guidelines !
This is my question :

I want to write a vb.net program that does completely automatically what,
until

now, I do manually, witch is describe below :

1. I launch IE (6)

2. I browse to my desired download page, say
http://www.site.com/download

This download page contains some textboxes, checkboxes,

radiobuttons, a DOWNLOAD BUTTON and text

3. I check some checkboxes, select some radiobuttons, enter text in some

textboxes and click on the download button

4. I receive a File Download Dialog

I browse to select a path/filename for the file

I click on the save button

The file is then saved on my pc.

Now I want a vb.net program that does the following :

1. Browses, SILENTLY, to my desired download page
(http://www.site.com/download) and fills in a form

SILENTLY means :

. no visible browse page (I do not want to see the download page

as in IE)

. vb.net code must be able to check some checkboxes, select some

radiobuttons, enter text in some textboxes

. after filling in data, vb.net code must be able to click the
Download button

2. vb.net code must be able to trap (event) the returned data, always
SILENTLY, i.e.

must be able to trap the File Download Dialog, fills somewhere

(?) a path/filename and download the file

Hope this is comprehensible.

Any help, code/articles/HowTos.../, is welcome.

Thank you very well in advance.

Jean-Marie


推荐答案

Jean Marie,


我的想法是解决你的问题。


看看axwebbrowser,但不要将它拖到你的表格,使用

Internet Explorer模式。


看一下webclient.download文件。


用于你的第二个问题也是Axwebbrowser,而不是在

axwebbrowser模式而不是可见ible。


我希望这有帮助吗?


Cor
Hi Jean Marie,

My idea''s to solve your problem are.

Have a look at the axwebbrowser, but do not drag it to your form, use the
Internet Explorer mode.

Have a look at the webclient.downloadfile.

Use for your second question also the Axwebbrowser, but than in the
axwebbrowser mode and than not visible.

I hope this helps?

Cor


谢谢你的支持你的回答。

看来我可以做第一部分,直到文件下载..

我还有的问题是:

我做' '知道如何停止显示文件下载对话框,用

Axwebbrowser / mshtml?

我不知道如何获取流(如同

HttpWebRequest / HttpWebRespponse类)读取请求的数据,用

Axwebbrowser / mshtml?。


任何其他想法,指南,文章,参考?

Jean-Marie


" Cor" < no*@non.com>在消息中写道

新闻:%2 **************** @ tk2msftngp13.phx.gbl ...
Thank your for your answer.
It seems I can do the first part until file download..
The problems I still have is :
I do''nt know how to stop the File Download Dialog to appear, with
Axwebbrowser/mshtml ?
I do''nt know how to get a stream (as with
HttpWebRequest/HttpWebRespponse classes) to read the requested data, with
Axwebbrowser/mshtml ?.

Any other idea, guidelines, articles, references ?
Jean-Marie

"Cor" <no*@non.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
嗨Jean玛丽,

我的想法是解决你的问题。

看看axwebbrowser,但不要把它拖到你的表格,使用
Internet Explorer模式。

查看webclient.download文件。

第二个问题也用于Axwebbrowser,但在
axwebbrowser模式下使用比不可见。

我希望这有帮助吗?

Hi Jean Marie,

My idea''s to solve your problem are.

Have a look at the axwebbrowser, but do not drag it to your form, use the
Internet Explorer mode.

Have a look at the webclient.downloadfile.

Use for your second question also the Axwebbrowser, but than in the
axwebbrowser mode and than not visible.

I hope this helps?

Cor



> ;我不知道如何使用
> I do''nt know how to stop the File Download Dialog to appear, with
Axwebbrowser / mshtml停止出现文件下载对话框?
我不知道如何获取流(与
HttpWebRequest / HttpWebRespponse类)用Axwebbrowser / mshtml读取请求的数据?
Axwebbrowser/mshtml ?
I do''nt know how to get a stream (as with
HttpWebRequest/HttpWebRespponse classes) to read the requested data, with
Axwebbrowser/mshtml ?.




正如我所说的那样下载到 webclient.downloadfile"。


Cor



As I said have a look for the download to "webclient.downloadfile".

Cor


这篇关于用于自动Web文件下载的vb.net程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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