با سلام
کاری نداره کافیه درون کلاس کدنویسی کنید
به همین سادگی:
class Class1
{
public void IDE(System.Windows.Forms.Panel pnl,System.Drawing.Color PanelColor,System.Windows.Forms.Label lbl,string LabelText,System.Windows.Forms.PictureBox PicBox,System.Drawing.Image PictureBoxImage, System.Windows.Forms.Timer tmr)
{
pnl.Visible = true;
pnl.BackColor = PanelColor;
lbl.Text = LabelText;
PicBox.Image = PictureBoxImage;
tmr.Enabled = true;
}
}
مثال استفاده :
private void button1_Click(object sender, EventArgs e)
{
Class1 c = new Class1();
c.IDE(panel1, Color.Red, label1, "ثبت کالا با موفقیت انجام شد", pictureBox1, Properties.Resources.danialafshari, timer1);
}
موفق باشید