Hi,
if the button is a descendant control of the control which is scrolling
then it will be scrolled along with the control it is part of. To stop your
button scrolling you could either change it's location as the control is
scrolling so it appears to stay in the same place, but I do not recommend
this as the button will jerk around as it is moved, or another alternative is
to move the button outside of the control's child control collection that is
being scrolled, but place it ontop of the control location wise so that it
appears to be in the scrollable area.
For example you can add a button and a panel to the forms Controls
collection, make the panel scrollable and have it contain all of the content,
not the form directly, then move your button ontop of the panel (make sure
it's z-order is greater than that of the panel i.e call BringToFront()) and
now you can scroll the panel but the button will remain stationary.
Mark.
--
http://www.markdawson.org
"Er********@gmail.com" wrote:
Hi,
Can i cause scrollbars to be activate only on part of the form?
Meaning"
I have buttons in top of form which i don't want scrollbars to scroll
this button. I want this button to be available even if acroll bars are
activated.
TIA.