Click to return to the Reusing Browser Technology home page    
IHTMLElement2::get_scroll...     IHTMLElement2::get_scroll...     IHTMLElement2 Interface    
Web Workshop  |  Reusing Browser Technology

IHTMLElement2::get_scrollTop Method


Retrieves the distance, in pixels, between the top of the object and the topmost portion of the content currently visible in the window.

Syntax

HRESULT get_scrollTop(
    VARIANT *p
);

Parameters

p
Address of a VARIANT structure that returns the element's scrollTop parameter.

Return Value

Returns S_OK if successful, or an error code otherwise.

See Also

scrollLeft, scrollHeight scrollWidth


IHTMLElement2::put_scrollTop Method


Sets the distance, in pixels, between the top of the object and the topmost portion of the content currently visible in the window.

Syntax

HRESULT put_scrollTop(
    VARIANT v
);

Parameters

v
VARIANT structure that contains the scrollTop value to set.

Return Value

Returns S_OK if successful, or an error code otherwise.

See Also

scrollLeft, scrollHeight crollWidth


Back to topBack to top

Did you find this topic useful? Suggestions for other topics? Write us!

© 1999 Microsoft Corporation. All rights reserved. Terms of use.