Jonah Harrison
Jonah Harrison

Reputation: 1

How can i click a button that has no id using it class in vb.net

I'm trying to click the login button on https://mobile.twitter.com/login I tried using

webbrowser1.document.getelementbyid("").InvokeMember("click")

But this wont work because the is no id or name linked to the button. I'm using vb.net.

Thanks for any help.

Upvotes: 0

Views: 401

Answers (1)

CruleD
CruleD

Reputation: 1173

You are clicking "Nothing" that way.

You need to point it at the element, then click. For example :

webbrowser1.Document.GetElementsByTagName("input").Item(10).InvokeMember("click")

Upvotes: 1

Related Questions