Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9002259
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T00:32:48+00:00 2026-06-16T00:32:48+00:00

I have a winform app in which I have a panel control. I want

  • 0

I have a winform app in which I have a panel control.

enter image description here

I want to be able to scroll inside the panel and place controls vertically more then the current height of the control and then have a scroll which will help me to see all the controls, how can I achieve that?

This is the designer code as well, in case someone wants to take a look at the code:

private void InitializeComponent()
{
  this.panel1 = new System.Windows.Forms.Panel();
  this.SuspendLayout();
  // 
  // panel1
  // 
  this.panel1.AutoScroll = true;           
  this.panel1.BackColor = System.Drawing.SystemColors.ControlLightLight;
  this.panel1.Location = new System.Drawing.Point(12, 12);    
  this.panel1.Name = "panel1";
  this.panel1.Size = new System.Drawing.Size(267, 365);
  this.panel1.TabIndex = 0;
  // 
  // Form2
  // 
  this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
  this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
  this.ClientSize = new System.Drawing.Size(456, 410);
  this.Controls.Add(this.panel1);
  this.Name = "Form2";
  this.Text = "Form2";
  this.ResumeLayout(false);
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T00:32:49+00:00Added an answer on June 16, 2026 at 12:32 am

    Since you have AutoScroll = true, you shouldn’t have to do anything. Any control that you place in the panel that is below the visible boundary will automatically create the appropriate scroll distance in the panel.

    If you want to manually override that, set AutoScroll = false and set the size of the canvas yourself using the AutoScrollMinSize property, example:

    panel1.AutoScrollMinSize = new Size(0, 1200);
    

    You might want to consider anchoring the panel to the four sides of the form as well, or dock-fill, since it looks like a resizable form. Again, the panel will handle the scrollbar size for you.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a panel in winforms app in which I want to display some
I have a Winform app which lists a batch of invoices in a gridview.
I have own component which works in my testing winform app good but when
I have a Winform App that uses a 3rd Party Library of Controls, DevExpress.
I have a WinForm app that displays results in a Gridview control. If a
I have a winform app, which shows some information in time, every time it
I have a WinForm, in which I am hiding all borders and the Control
I am developing a c# winform app which controls a website using web browser.
I have an existing winform app which didn't use Program.cs. I wanted to add
I have a C# winform app which is doing a lot of calculation. there

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.