Webbrowser click on image button by class

Thanks for read my question.

I have this button in website page, i need click using twebbrowser.

<td class="Send"><input type="image" src="http://imageofbuton.com/imagemybuttonexample.gif" class="send-button"></td>

Open in new window

How i do to click using the "CLASS" of the button, because dont have name or text, only image and class.

Any solution to click in this button?

Thanks in advance.
Who is Participating?
Ferruccio AccalaiSenior developer, analyst and customer assistance Commented:
You  can put this code wherever you prefer
I've put it in NavigateComplete to be sure to have a document loaded

procedure TForm1.WebBrowser1NavigateComplete2(ASender: TObject; const pDisp: IDispatch; var URL: OleVariant);
  ovElements: OleVariant;
  i: Integer;
  ovElements := WebBrowser1.OleObject.Document.all;
  for i := 0 to (ovElements.Length - 1) do
    if (ovElements.item(i).className = 'send-button') then //be aware that it must be written with the exact case className

If you have more than one element with that class you can filter more using other elements tags ('id', 'name' and so on)
Suzy1985Author Commented:
Good job, Thank you!

Merry Christmas and Happy Holidays.  ;)
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.