[Closed] FlowLayoutPanel scoll limitation?
What a pain. Well I might be able to scale and slide the positions of the bars based on a scroll bars position. So I use a scroll bar control instead of the one in the FLP and then just move the bars as I need them. This is way more of a pain but possible. I would also have to store the real values of the bars in the tag property as once they get over 32767 they would not be correct any more. So if I just slide and don’t try and add, remove that might work a bit easier. What an incredible pain in the butt. What I have going already works so well and looks so cool and now I have to rip the guts out of it for about the eighth time.
Thanks Denis, I know that it is a short problem just odd they way we can over ride it one way and not another.
So does any one know how to get a ScrollableControl worked correctly?
First off it will not retain the position that you set it at. It just pops back to the start position. Most mouse events (mouseUp) don’t appear to work. I can see that when I first create it that the value goes from 0 to 100 but if I set autoScroll to false set the horizontal min and max values really high then I get something different. First when I touch and slide I get the 0 to 100 value but as soon as I let go the slider changes size and I now get the value going from the min to the max. I can’t see a way to set it to do one other other how ever.
My current work around is to use some other control and enable the scroll on it and use the width of the control to set the scale of it.
scrollBar=dotNetObject "system.windows.forms.ScrollableControl"
scrollBar.HorizontalScroll.visible=true
scrollBar.HorizontalScroll.enabled=true
scrollBar.bounds=dotNetObject "system.drawing.rectangle" 0 (splitContainer.panel2.height-20) splitContainer.panel2.width 20
scrollBar.dock=scrollBar.dock.bottom
scrollBar.autoScroll=true
Sorry I missed a point. Why do you prefer to use other ScrollableControl as a replacement for the FlowLayoutPanel’s one?
I see the idea. Just struck me as I was setting up the work around. You have to have a control added to it. I can just stick a label in it and use the width of the label to get the scroll to work as I need.
yes, you can change size of a control if it’s not higher then 32767, but you can’t change a position over 32767… Probably it will be better to have universal method for both move and scale operations.
I need to fake the scrolling as I need to go way past 32767. So now I’m just trying to slide every thing into the visible area as needed. Another problem still remains, when I first launch the UI the scroll bar will set it self at the correct size and allow for scrolling way past that value. I’m doing that by setting a label in the ScrollableControl at the length that I need. I can set the width of that label as wide as I like. If I try and change the width in any way it reverts back to 32767 or under.
So, now I delete the label and readd it ever time I want to scale the time line:S