Bit obscure question but someone might have done it. I want to zoom in on a clicked document element. Without going into all the details, I am just getting the ID of element and splitting it into a string command typ and a number argument arg. Then zoom and scroll as here:
'test of zoom in on element
Case "zoomin"
ZoomBrowser(arg)
MainBox2.Document.Body.ScrollTop = MainBox2.Document.Body.ScrollTop + arg
When I first click the element it zooms but doesn't scroll. If I click again it then scrolls as expected. I would assume this is something to do with the redrawing of the document being incomplete when I attempted to do the scrolltop but it isn't going through the DocumentCompleted event after the zoom, so not sure how to get round the problem.
Ta for any input.
'test of zoom in on element
Case "zoomin"
ZoomBrowser(arg)
MainBox2.Document.Body.ScrollTop = MainBox2.Document.Body.ScrollTop + arg
When I first click the element it zooms but doesn't scroll. If I click again it then scrolls as expected. I would assume this is something to do with the redrawing of the document being incomplete when I attempted to do the scrolltop but it isn't going through the DocumentCompleted event after the zoom, so not sure how to get round the problem.
Ta for any input.
Comment