I know this has been answered elsewhere, but I can't get the basics to run... Regardless of the application purpose (which is obvious)
private void btnSave_Click(object sender, EventArgs e)
{
// these are *internal* properties of the NET appilcation
FileSystemWatcher.Properties.Settings.Default.MailServer = Convert.ToString(txtMailServer);
FileSystemWatcher.Properties.Settings.Default.ServerPort = Convert.ToInt16(txtServerPort.Text);
FileSystemWatcher.Properties.Settings.Default.Subject = Convert.ToString(txtSubject);
FileSystemWatcher.Properties.Settings.Default.MessageFrom = Convert.ToString(txtMessageFrom);
FileSystemWatcher.Properties.Settings.Default.MessageTo = Convert.ToString(txtMessageTo);
FileSystemWatcher.Properties.Settings.Default.Save();
}
First issue is that I get a bunch of these exceptions when I hit this code...
Exception thrown: 'System.Security.SecurityException' in mscorlib.dll
No other runtime errors I can see... The app.config appears to be structured correctly - using Project-Add New Item.. etc and inspecting the app.config contents. But the SAVE function listed above - doesn't save any changes I may make.
thanks