wusher
wusher

Reputation: 12441

Is there a way to convert from System.Windows.Forms.HtmlElement to mshtml.IHTMLElemenet3?

Is there a way to convert from System.Windows.Forms.HtmlElement to mshtml.IHTMLElemenet3?

--edit after answer accepted -- This is what the code would look like.

HtmlElement myElement = getElementByID(id);
IHTMLElement3 h3 = (IHTMLElement3) myElement.DomElement;

Thanks @korchev

Upvotes: 2

Views: 2102

Answers (1)

Atanas Korchev
Atanas Korchev

Reputation: 30671

Just cast the DomElement property to mshtml.IHTMLElement3

Upvotes: 1

Related Questions