private void Load_Conf_Click(object sender, EventArgs e) { Microsoft.Win32.OpenFileDialog dlg = new Microsoft.Win32.OpenFileDialog(); dlg.DefaultExt = ".xml"; dlg.Filter = "Text documents (.xml)|*.xml"; Nullable <bool> result = dlg.ShowDialog(); if (result == true) { string pathToFile = dlg.FileName; client.readConfig(pathToFile); } }
public MainWindow() { InitializeComponent(); client = new Client(this.chat, this.txtBlock, this); setChat(); string conf = ClientNode.App.partialPathToConfig; if (conf != null) { pathToConfig = @""+conf; client.readConfig(pathToConfig); } }
public MainWindow() { InitializeComponent(); client = new Client(this.chat, this.txtBlock, this); setChat(); string conf = ClientNode.App.partialPathToConfig; if (conf != null) { pathToConfig = @"" + conf; client.readConfig(pathToConfig); } }