Hi ashishk,
Please refer below sample.
Design
Code
C#
public Form1()
{
InitializeComponent();
}
Form2 f2;
private void button1_Click(object sender, EventArgs e)
{
f2 = new Form2();
f2.Show();
}
private void button2_Click(object sender, EventArgs e)
{
ClearControls(f2);
}
private void ClearControls(Control frm)
{
foreach (Control control in frm.Controls)
{
if (control is TextBox || control is ComboBox)
{
control.ResetText();
}
if (control is CheckBox)
{
((CheckBox)control).Checked = false;
}
}
}
Screenshot