123456789101112131415161718192021222324252627282930313233343536373839404142434445 |
- 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_Process : UserControl
- {
- private string cutHoleName;
- public string CutHoleName { get => cutHoleName; set => cutHoleName = value; }
- private FormHOZMain formHOZMain;
- public FormHOZMain FormHOZMainObject { get => formHOZMain; set => formHOZMain = value; }
- public UControl_Process(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;
- }
- }
- }
- }
- }
- }
- }
|