| 12345678910111213141516171819202122232425262728293031323334353637383940414243 |
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Drawing;
- using System.Data;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- using System.Windows.Forms;
- namespace HOZProject
- {
- public partial class UControl_ParaInfo : UserControl
- {
- private FormHOZMain formHOZMain;
- public FormHOZMain FormHOZMainObject { get => formHOZMain; set => formHOZMain = value; }
- public UControl_ParaInfo(FormHOZMain formHOZ)
- {
- InitializeComponent();
- FormHOZMainObject = formHOZ;
- }
- private void btnClose_Click(object sender, EventArgs e)
- {
- foreach (Control item in FormHOZMainObject.plFill.Controls)
- {
- if (item is Panel)
- {
- foreach (Control itemControl in item.Controls)
- {
- if (itemControl.Name == this.Name)
- {
- item.Controls.Remove(this);
- this.Dispose();
- item.Visible = false;
- break;
- }
- }
- }
- }
- }
- }
- }
|