I am trying to set VScroll or SetScrollState on a Panel but i cannot access the protected members altough i read this:
|
The protected keyword is a member access modifier. A protected member is accessible within its class and by derived classes.
...
A protected member of a base class is accessible in a derived class only if the access takes place through the derived class type.
| |
in here:http://msdn2.microsoft.com/en-us/library/bcd5672a(VS.80).aspx
I cannot access VScroll from Panel instance; Panel derives from ScrollableControl so it should've worked.
I tried even setting a property that accessess the protectedmember on a class derived from Panel. It seemed to access it but it didn't changed anything so it wasn't a solution.
MSDN:
|
To manually override which scroll bars are visible, set the VScroll and HScroll properties. If either property is set to false, the corresponding scroll bar is not visible, even if the AutoScroll property is set to true.
| |
So if it accessed it it should've set the scroll bar visibility to false; i tried SetScrollState too, it didn't work.
I cannot tell wich is the problem, protected accessign or Panel implementation.