using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using DevComponents.DotNetBar;
using DevComponents.DotNetBar.Controls;

namespace CsharpTest
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}

private void btnAdd_Click(object sender, EventArgs e)
{
foreach(Control c in this.panelEx1.Controls)
{
if(c is DevComponents.DotNetBar.Controls.TextBoxX)
{
c.Text
= "123";
}
else
{
c.Text
= "名称!";
}
}
}

private void btnClear_Click(object sender, EventArgs e)
{
foreach(Control d in this.panelEx1.Controls)
{
if(d is DevComponents.DotNetBar.Controls.TextBoxX)
{
d.Text
= "";
}
else
{
d.Text
= "更改后的名称";
}
}
}
}
}
private void ClearText()
{
foreach (Control myControl in this.panelTable.Controls)
{
if (myControl is DevComponents.DotNetBar.LabelX)
{
continue;
}

myControl.Text
= "";
}
}

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-11-21
  • 2022-12-23
  • 2021-09-18
  • 2021-08-16
  • 2022-12-23
猜你喜欢
  • 2021-07-31
  • 2022-12-23
  • 2021-10-20
  • 2022-12-23
  • 2022-12-23
  • 2021-05-16
  • 2022-12-23
相关资源
相似解决方案