Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C#
  4. Add panel

Add panel

Scheduled Pinned Locked Moved C#
3 Posts 2 Posters 1 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    shamsteady
    wrote on last edited by
    #1

    Im trying to add panel in window form by using this method. public class Form1 : System.Windows.Forms.Form { private System.Windows.Forms.Panel mypanel; private void InitializeComponent() { ... this.mypanel = new System.Windows.Forms.Panel(); ... } ... ... this.Controls.Add(this.mypanel); Is there other way to display panel besides using "this.Controls.Add(this.mypanel);" method?

    D 1 Reply Last reply
    0
    • S shamsteady

      Im trying to add panel in window form by using this method. public class Form1 : System.Windows.Forms.Form { private System.Windows.Forms.Panel mypanel; private void InitializeComponent() { ... this.mypanel = new System.Windows.Forms.Panel(); ... } ... ... this.Controls.Add(this.mypanel); Is there other way to display panel besides using "this.Controls.Add(this.mypanel);" method?

      D Offline
      D Offline
      Dawid Mazuruk
      wrote on last edited by
      #2

      Yes, you can use: this.mypanel.Parent = this;

      S 1 Reply Last reply
      0
      • D Dawid Mazuruk

        Yes, you can use: this.mypanel.Parent = this;

        S Offline
        S Offline
        shamsteady
        wrote on last edited by
        #3

        Thanks...

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups