void LoadSettings() { string settingFile = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData)+@"\Ortelius\settings.ors"; if(File.Exists(settingFile)){ try{ FileStream myStream=new FileStream(settingFile,FileMode.Open,FileAccess.Read); myStream.Seek(0,SeekOrigin.Begin); BinaryFormatter binLaeser=new BinaryFormatter(); appSettings = (GenerelSettings) binLaeser.Deserialize(myStream); myStream.Close(); LoadProject(); } catch(Exception e){ MessageBox.Show(e.ToString()); } } }
//Initialize void InitStuff() { projSettings = new ProjectSettings(); appSettings = new GenerelSettings(); populateStyleCombo(); changeFlag = false; newVersion.Visible = false; //checkForUpdates(); }