dattebayo
dattebayo

Reputation: 2072

Element offset and client positions in BHO

How to find the position of the HTMLElement in BHO(C#)?

I need both offset position of the element in the page and the client position of the element i.e. position of the element from the Left-Top of the client window.

Upvotes: 1

Views: 368

Answers (1)

dattebayo
dattebayo

Reputation: 2072

I solved this problem myself.

The getClientRects() and getBoudningClientRect() methods of IHTMLElement2 are very helpful with this regard.

-Datte

Upvotes: 1

Related Questions