通过vb.net应用程序在我的网站上填写表格 [英] Fill in a form on my website from vb.net application

查看:68
本文介绍了通过vb.net应用程序在我的网站上填写表格的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想从vb.net应用程序向我的网站上的表单发送一个值,我完全不知道如何处理.

I'd like to send a value from my vb.net application to a form on my website and I have absolutely no idea how to go about it.

该网站是在Linux服务器上运行的wordpress网站.
该页面的表单中包含字段SerialNo,Name和& ;;电子邮件.

The website is a wordpress site running on a Linux server.
The page has a form with fields SerialNo, Name, & Email.

我只想在默认浏览器中打开页面,并在用户单击我的应用程序中的按钮时自动填写serialNo字段. (序列号由我的应用程序生成)

I'd just like to open the page in the default browser and fill in the serialNo field automatically when the user clicks a button in my application. (The serial No is generated by my app)

然后,用户可以填写其余字段,然后提交表单.

The user can then fill out the rest of the fields and then submit the form.

我不知道该怎么做.我需要使用PHP还是比PHP更简单?

I have no idea how to go about this. Do I need to use PHP or is it simpler than that?

欢呼

Andy 

Andy 

推荐答案

每个网络浏览器都有不同的对象模型,因此您将无法自动化.也就是说,除非您想为应用程序支持的每个网络浏览器编写不同的代码.如果您不想使用WebBrowser控件,则可能是 您最好的机会使它正常工作,然后您就只剩下

Each web browser has a different object model so you won't be able to automate. That is, unless you want to write different code for each web browser your app is supporting. If you don't want to use the WebBrowser control, and it's probably your best chance at getting this to work, then you are pretty much left with the SendKeys Class.

另一个想法是,如果Web应用程序支持查询字符串,则可以通过url传递序列号,这将解决您的自动化问题.这将使用 Process.Start .

Just another thought, if the web app supports a query string you could pass the serial number in through the url and that would resolved your automation issue. This would be done using Process.Start.


这篇关于通过vb.net应用程序在我的网站上填写表格的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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