Re: How can I automate a task like open browser and click a button?
Shawn Wildermuth <[email protected]>
| Newsgroups | gmane.comp.windows.devel.dotnet.web |
|---|---|
| Message-ID | <[email protected]> |
First, please don't cross post your questions to multiple mailing lists until you fail to get an answer on one. TO launch a new browser window is easy, just launch iexplorer.exe (or your favorite browser) with the desitanation as a commandline parameter. But setting a value and clicking it could be much harder. What are you trying to accomplish? Thanks, Shawn Wildermuth Wildermuth Consulting Services, LLC http://adoguy.com C# MVP, MCSD.NET, Author and Speaker -----Original Message----- From: Discussion of building .NET applications targeted for the Web [mailto:[email protected]] On Behalf Of Lior Levy Sent: Sunday, December 24, 2006 4:55 PM To: [email protected] Subject: [DOTNET-WEB] How can I automate a task like open browser and click a button? Hi, How can I automate a task like open a new browser add a text to a textBox and click a button from a webForm? From winForm it dose like this: HTMLDocument myDoc = new HTMLDocumentClass(); myDoc = (HTMLDocument) axWebBrowser1.Document; HTMLInputElement otxtSearchBox = (HTMLInputElement) myDoc.all.item("q", 0); otxtSearchBox.value = "intel corp"; HTMLInputElement btnSearch = (HTMLInputElement) myDoc.all.item("btnI", 0); btnSearch.click(); Thanks, Lior. =================================== This list is hosted by DevelopMentor® http://www.develop.com View archives and manage your subscription(s) at http://discuss.develop.com =================================== This list is hosted by DevelopMentor® http://www.develop.com View archives and manage your subscription(s) at http://discuss.develop.com