Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Top-level control cannot be added to a control

Tags:

People also ask

What is top level control?

The highest level of management within a business is the top-level management; this is the first of the three levels. The top management definition refers to the executive managers who lead the organization as a whole and have the most authority when making business decisions.

Which method is used to add the control on window?

ControlCollection. Add(Control) Method.

How do I add different controls to my form?

Add the control by drawingSelect the control by clicking on it. In your form, drag-select a region. The control will be placed to fit the size of the region you selected.


How to Load other Form inside panel in a primary form.

i was trying something like

private void frmInitialEntryBooks_Load(object sender, EventArgs e) {     frmSujbect objForm = new frmSujbect();     pnl.Controls.Add(objForm);     objForm.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;     objForm.Dock = DockStyle.Fill;     objForm.Show(); } 

but it throw exception Top-level control cannot be added to a control at line pnl.Controls.Add(objForm);