Menu
Forums
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Trending
What's new
New posts
New profile posts
Latest activity
Members
Current visitors
New profile posts
Search profile posts
Upgrades
Log in
Register
What's new
Search
Search
Search titles only
By:
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
Software Development
Programming
Programming Q&A
Value from both WebBrowser and TextBox in VB
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="flyest" data-source="post: 353138" data-attributes="member: 29020"><p>Here's an If code for my new betting bot project.</p><p>[CODE]If WebBrowser1.DocumentText.Contains("You lost 12 800 000") Then</p><p> WebBrowser1.Document.GetElementById(TextBox6.Text).SetAttribute("value", TextBox4.Text * "4")</p><p> For Each el As HtmlElement In elc</p><p> If el.GetAttribute("type").Equals("submit") Then</p><p> el.InvokeMember("Click")</p><p> End If</p><p> Next</p><p> End If[/CODE]</p><p>I basically want to do the same thing in the first line as I do in the second (SetAttribute).</p><p>I want to know how I can make WebBrowser1 know if WebBrowser1.DocumentText.Contains both 'You lost' (HTML text) and text from TextBox1. </p><p></p><p>I didn't know how to explain this in a better way, but here's a demonstration in code on how I want it. Might help you.</p><p>[CODE]WebBrowser1.DocumentText.Contains("You lost" And TextBox1.Text)[/CODE]</p></blockquote><p></p>
[QUOTE="flyest, post: 353138, member: 29020"] Here's an If code for my new betting bot project. [CODE]If WebBrowser1.DocumentText.Contains("You lost 12 800 000") Then WebBrowser1.Document.GetElementById(TextBox6.Text).SetAttribute("value", TextBox4.Text * "4") For Each el As HtmlElement In elc If el.GetAttribute("type").Equals("submit") Then el.InvokeMember("Click") End If Next End If[/CODE] I basically want to do the same thing in the first line as I do in the second (SetAttribute). I want to know how I can make WebBrowser1 know if WebBrowser1.DocumentText.Contains both 'You lost' (HTML text) and text from TextBox1. I didn't know how to explain this in a better way, but here's a demonstration in code on how I want it. Might help you. [CODE]WebBrowser1.DocumentText.Contains("You lost" And TextBox1.Text)[/CODE] [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Software Development
Programming
Programming Q&A
Value from both WebBrowser and TextBox in VB
Top