I created a lanchat program. I want to make a settings section. I designed it in a new form that called settings and i put on the settings form one checkbox.With this checkbox I want to start in the main form one automatic logging timmer what log into one file the chat,i can start the autosave and it work fine:) but ever when close the settings form and i reopen the settings form the checkbox state is unchecked:cursing:,vainly checked it before closing and reopening:cursing:
my source code what check the autostart timer state on the form1 and "enable/disable" the checkbox
{
InitializeComponent();
Form1 form = new Form1();
if (form.autosave.Enabled == true)
{
this.checkBox1.Checked = true;
this.checkBox1.CheckState = CheckState.Checked;
}
else
{
this.checkBox1.Checked = false;
this.checkBox1.CheckState = CheckState.Unchecked;
}
}
Any idea?


Sign In
Create Account


Back to top









