Naturally, the code you posted will not find the tag you posted. It searches for labels of type input :
webBrowser1.Document.GetElementsByTagName("input")
But as you say (and demonstrate):
But my webpage button has different tags.
So you need to look for the tags (tags) that you are using. Something like that:
webBrowser1.Document.GetElementsByTagName("a")
This will return the anchor elements in the document. Then, of course, you need to find the specific (s) that you want to click. What does this line do:
if (element.GetAttribute(attribute).Equals(attName))
Does it determine that the target tag is completely dependent on the values ββfor these variables, which I assume you know and can control.
David source share