473,385 Members | 1,764 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Scrolling panel

Hi,

I have a panel on a form that contains a number of controls, so many that
the panel has a vertical scrollbar in order to view all of them. When the
form first loads, the panel's scrollbar automatically scrolls to about the
middle rather than staying at the top. Also, when I click on one of the
controls, a dialog box appears to allow me to edit it's information. When I
click OK on the dialog box, the information on the control is changed, and
the panel's scrollbar once again scrolls to the middle. This last scenario
only happens once, on the first control I click. After that everything
works as it should. Does anyone have any idea what's going on, or what
event is firing to cause the panel to scroll automatically sometimes?

Thanks,
Nathan
Nov 21 '05 #1
2 4750
Hi,

Make sure the panels autoscrollpostion, and autoscrollmargin are set
to 0,0

http://msdn.microsoft.com/library/de...argintopic.asp

http://msdn.microsoft.com/library/de...itiontopic.asp

Ken
---------------
"Nathan" <nk*********************@softhome.net> wrote in message
news:ej**************@TK2MSFTNGP11.phx.gbl...
Hi,

I have a panel on a form that contains a number of controls, so many that
the panel has a vertical scrollbar in order to view all of them. When the
form first loads, the panel's scrollbar automatically scrolls to about the
middle rather than staying at the top. Also, when I click on one of the
controls, a dialog box appears to allow me to edit it's information. When I
click OK on the dialog box, the information on the control is changed, and
the panel's scrollbar once again scrolls to the middle. This last scenario
only happens once, on the first control I click. After that everything
works as it should. Does anyone have any idea what's going on, or what
event is firing to cause the panel to scroll automatically sometimes?

Thanks,
Nathan

Nov 21 '05 #2
Thanks Ken. The properties are set correctly in the designer, and I've also
tried the following code:

Me.pnlPCard.AutoScrollMargin = New Size(0, 0)
Me.pnlPCard.AutoScrollPosition = New Point(0, 0)

I've tried this at the beginning and end of my form_load subroutine as well
as in the designer generated code. Still getting the strange behavior. The
controls are all added at design time, if that makes a difference.

Thanks,
Nathan
Nov 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Amrit | last post by:
Hi Can anyone help me? I would really appreciate I am trying to scroll Groupboxes inside the panel when i hold panel's scroll bar and drag up and down. Such as Internet explorer where you can hold...
4
by: Nathan | last post by:
I need a panel with only a vertical or only a horizontal scroll bar. Is there a way to do that? Nathan
0
by: Al | last post by:
Hi, I am using large PictureBox inside a Panel, user can write on the PictureBox (it is actually InkPicture) but the problem that I have is regarding the Auto scrolling of the panel.. For...
5
by: Sam | last post by:
Hi, I would like to reproduce the same control as in Visual Studio for the propery editor or the message feedback window. That is, a scrolling panel that would appear when the mouse is over one of...
1
by: John | last post by:
Can I use the Atlas controls to create a scrolling panel in a webform? Basically I want a master page that defines 90% of the screen height to be a workspace, with 5% top and bottom for other...
0
by: Elroyskimms | last post by:
I have a fixed witdth panel control with horizontal scrollbars. In it, I load a table and in each table cell is an instance of a user control that I created it. In theory, 3-5 of these controls are...
2
by: shahoo | last post by:
Hi, I am trying to add some controls (say buttons) to a panel. At some stage the controls are too much to be show on the panel, so I set the Autoscroll property of the panel to true. But my...
0
by: mike | last post by:
Hi guys, I have a windows form and on load event I dynamically created a panel and dynamically create/add pictureboxes to panel and added a panel to the form with docking with fill. I am...
4
by: mateusz.zajakala | last post by:
Hi, I have panel (with autoscroll property) on which I'm dynamicaly adding of controls. When I want to scroll my panel using scrollbars it freezes all the controls added on that panel, makes...
2
by: luker | last post by:
Hi Experts, I'm trying to create a panel-derived class with Autoscroll = true that scrolls horizontally when using <Shift>+Mousewheel. Sounds like a straight forward task, doesn't it? I tried...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.