SCROLL Attribute | scroll Property

Sets or gets a string value that indicates whether the scroll bars are displayed.

Syntax

HTML <HTA:APPLICATION SCROLL = sScroll... >
Scripting [ sScroll = ] HTA:APPLICATION.scroll

Possible Values

sScroll String that specifies one of the following values.
yes
Default. Scroll bars are displayed.
no
Scroll bars are not displayed.
auto
Scroll bars are displayed only when the content exceeds what can fit in the client area.

The property is read-only. The property has a default value of yes.

Remarks

Note  The scroll property is read-only; however, the SCROLL attribute can be used to set the initial value.

Set the body. scroll property to no as an alternate way to prevent scroll bars from being displayed.

Example

This example shows how to get the scroll property.

<HTML>
<HEAD>
<HTA:APPLICATION 
 ID=oHTA 
 SCROLL="no"/>
<TITLE>HTA Properties</TITLE>
<STYLE>
BODY {font-size: 8pt; font-family: Arial;}
</STYLE>
</HEAD>

<SCRIPT>
function readFun()
{
alert("The scroll property is set to:  " + oHTA.scroll);
}
</SCRIPT>

<BODY> 
<P>Read the property: 
<INPUT TYPE="button"  VALUE="Test scroll value" onClick="readFun()"/>
</P>
<p>.</p><p>.</p><p>.</p><p>.</p><p>.</p>
<p>.</p><p>.</p><p>.</p><p>.</p><p>scroll down</p>
<p>.</p><p>.</p><p>.</p><p>.</p><p>.</p>
<p>.</p><p>.</p><p>.</p><p>.</p><p>scroll down</p>
<p>.</p><p>.</p><p>.</p><p>.</p><p>.</p>
<p>.</p><p>.</p><p>.</p><p>.</p><p>scroll down</p>
</BODY>
</HTML>

Applies To

HTA:APPLICATION