Welcome to the SRP Forum! Please refer to the SRP Forum FAQ post if you have any questions regarding how the forum works.
How does the vertical scroll bar of the MDI control work?
Some of our users have started working from home on small laptop screens, and our app is too big for their screens. Our app is contained within an MDI control, so technically they can manually scroll the vertical scroll bar of the MDI control to see everything, but it would be better if the mouswheel did it.
While I could qualify the mousewheel event and manually move the vertical scrollbar of the MDI control, this seems wrong to me, as I would except the "framework" to handle this for me. Am I wrong in assuming that the framework does this for you, meaning that I need to do it myself?
While I could qualify the mousewheel event and manually move the vertical scrollbar of the MDI control, this seems wrong to me, as I would except the "framework" to handle this for me. Am I wrong in assuming that the framework does this for you, meaning that I need to do it myself?
Comments
i just found out that you can actually scroll a window itself using this code, which is interesting, as this could be another way to solve this issue
result = Send_Message(@window, "SCROLL", 0, -100)
This means you could make an OI form into a webpage.
I can also see that you actually need to set the size property for each window to "move them into view", which is worrying as I don't trust the size property(as it can make invisible controls visible).
Yes and no. If you are only referring to an MDI Frame, then you can get a scrolling effect similar to a web page, but I still don't think the UX will be great. If you are referring to a regular OI form, then this won't behave as you might want because the scrollbar changes pages rather than navigates virtual space. This is why we created the SRP Panel control. That said, our control does not support mousewheel activity so I'm not suggesting it will completely solve your problems.
Are you aware that the SIZE property has a 5th value specifically to control how visibility is affected?
You could add a vertical scroll bar control to the form though.
Thank you I will have a look.
True, but what would you do with that? Would you reposition the controls on the form dynamically as the value of the scrollbar was changed?
If you create a really big form and then place controls on that form (in the normal static way), you can scroll down to see the controls that would otherwise be "off the screen".
The only problem is that the GUI designer doesn't really let you work with a big form. You can only make a form that is as big as your screen...which doesn't give you a lot of space to wok with.
Anyway, I have gotten the mdi thing working, so that will do.
And yes, i would use your panel control, but it's too late. We need a solution that works for our hundreds of existing forms.
I agree that the Form Designer is rather limiting in this area. You can put controls "off the screen", although it is challenging if you can't see what you are doing. Nevertheless, bringing them "onto the screen" is something that you can't do unless you use the SIZE property to reposition them or - as I mentioned earlier - use our SRP Panel control so you can have a true scrollable background where the controls move up and down automatically like a web page.
result = Send_Message(@window, "SCROLL", 0, -10)
The above code will scroll down, revealing stuff that was previously off the screen.