Discussion Thread
UniToolbox
Message Thread
The leading control suite for Unicode development in Visual Basic.
Posted in the UniToolbox Forum.
FAQ: UniToolbox FlexGrid Control Scrollbars
How can I determine whether the scroll bars are visible at run time in a UniFlexGrid control?
To detect whether the scroll bars were visible you can use calls to FindWindowEx to get the handle of a scrollbar in your control. Then using GetWindowLong to check whether you've found the horizontal or vertical one and whether it's visible or not.
The UniFlexGrid always displays a horizontal scrollbar if there is less than a scrollbar's width between the end of the last column and the edge of the control. You can manually calculate the width of all the columns in the grid, then determine whether the vertical scrollbar is visible and if so add it to the width so far, then see if that is greater than the width of the grid - then set the ScrollBars property to flexScrollBarBoth or flexScrollBarVertical to turn the horizontal one on or off.
FAQ: UniToolbox FlexGrid Control Scrollbars
How does this work with the UniGrid control as there is no ScrollBars property ?
FAQ: UniToolbox FlexGrid Control Scrollbars
This refers to UniFlexGrid, and not to UniGrid
FAQ: UniToolbox FlexGrid Control Scrollbars
Yes I know.
Thats why I asked how it works with the UniGrid control as I'd like to get rid of the scrollbars ?
FAQ: UniToolbox FlexGrid Control Scrollbars
I'm glad we're on the same page here. This is one of the reasons we created the FlexGrid control as it allows more control over the properties such as scrolling which is not available on the basic control.