Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Windows Forms / WinForm General / December 2004

Tip: Looking for answers? Try searching our database.

How to make user control scroll

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
moondaddy - 14 Dec 2004 16:07 GMT
I have a form (vb.net 1.1) where I place various user controls in the body
section of the form at runtime.  Often these controls will be larger than
the form (the form is resizable so I never know what the size is going to
be) and when it is, I need to have scrollbars available to the user.  I
thought I could simply put a panel control in the body of the form
(dock=fill), then place the user controls in the panel (uc.parent =
me.pnlBody) (dock=fill), but that didn't work.  I also set the panel's
AutoScroll property to true, but that didn't have any effect also.

Can anyone please advise on how to make scrollbars dynamically appear and
disappear as needed for the user controls?

Thanks.

Signature

moondaddy@nospam.com

Tim Jarvis - 15 Dec 2004 09:09 GMT
> the panel (uc.parent = me.pnlBody) (dock=fill), but that didn't work.
> I also set the panel's AutoScroll property to true, but that didn't
> have any effect also.
> Thanks.

As well as the autoscroll property you need to set the AutoScrolMinSize
or the AutoScrollMargin properties...

Check out the helpfile at (watch for wrapping)
ms-help://MS.VSCC.2003/MS.MSDNQTR.2003FEB.1033/cpref/html/frlrfsystemwin
dowsformsscrollablecontrolclassautoscrollmargintopic.htm

Regards Tim.

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.