How to have scrollbars in a user control
- From: "Raj" <rajendra.kamath@xxxxxxxxxxxxxxxxxx>
- Date: Tue, 16 Aug 2005 16:00:17 +0530
Hi,
I would like to have my user control to support scrollbars. So that when the
user control is embeded in a pane/view, and the view size is reduced to less
than the size of the usercontrol, the user control must show scroll bars.
Currently I tried by setting the AutoScroll property to true. Also, I
handled the 'Form1_SizeChanged' event for the form. Here I invoke a 'Resize'
routine defined by the UserControl - 'ResizeControl' :-
public void ResizeControl(int width, int height)
{
this.Left = 10;
this.Top = 10;
this.Height = (height - 20) ;
this.Width = (width - 20) ;
}
But I am finding that the scrolbars are not appearing correctly. Only one
scrollbar appears at a time?
Please suggest possible solutions!
Thanks & Regards,
Rajendra
.
- Follow-Ups:
- Re: How to have scrollbars in a user control
- From: Dmytro Lapshyn [MVP]
- Re: How to have scrollbars in a user control
- Prev by Date: Re: 1 configuration file for many applications/aspx/webservice
- Next by Date: Re: Remote access using Dialup Networking
- Previous by thread: How to pass pointer as an function argument in C#?
- Next by thread: Re: How to have scrollbars in a user control
- Index(es):
Relevant Pages
|