06-24-2018, 04:56 AM
Member function Htm.NavigateIndex_
example
Macro Macro21
function navig [Htm&result]
;Gets an element near this element in the collection of all elements in the document.
;Error if navig is too big and there is no element at the result index.
;navig - offset of the element index from the index of this element. For example, if -1, gets previous element in the collection.
;result - if used, receives the result. Else the result will be this variable.
MSHTML.IHTMLDocument2 d=el.document
MSHTML.IHTMLElementCollection c=d.all
int i=el.sourceIndex+navig
MSHTML.IHTMLElement t=c.item(i)
if(t=0) end ERR_BADARG
if(&result) result.el=t; else el=t
example
Macro Macro21