Compare commits
2
Commits
e05e8b2ea8
...
5b9adcb133
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5b9adcb133 | ||
|
|
050685b856 |
No files matched your search
@@ -4,9 +4,10 @@
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:local="clr-namespace:formula_manage.Windows"
|
||||
mc:Ignorable="d"
|
||||
mc:Ignorable="d" Loaded="Window_SQLBAK"
|
||||
Title="SQL_BAK" Height="450" Width="500">
|
||||
<Grid>
|
||||
|
||||
<CheckBox x:Name="SQL_bak" Height="19" Margin="5,6,315,0" VerticalAlignment="Top" Content="自定义备份地址" IsTabStop="False" Checked="SQLBAK_Checked" Unchecked="SQLBAK_Checked"/>
|
||||
|
||||
</Grid>
|
||||
</Window>
|
||||
@@ -21,7 +21,24 @@ namespace formula_manage.Windows
|
||||
{
|
||||
public SQL_BAK()
|
||||
{
|
||||
WindowStartupLocation = WindowStartupLocation.CenterScreen;
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public string INIPath = Convert.ToString(System.AppDomain.CurrentDomain.BaseDirectory) + "formula.ini";
|
||||
|
||||
private void Window_SQLBAK(object sender, RoutedEventArgs e)
|
||||
{
|
||||
UserClass.IniFile.IniFiles Configini = new UserClass.IniFile.IniFiles(INIPath);
|
||||
SQL_bak.IsChecked = Boolean.Parse(Configini.IniReadvalue("SQL_BAK", "S1"));
|
||||
}
|
||||
|
||||
private void SQLBAK_Checked(object sender, RoutedEventArgs e)
|
||||
{
|
||||
UserClass.IniFile.IniFiles Configini = new UserClass.IniFile.IniFiles(INIPath); //配置文件
|
||||
Configini.IniWritevalue("SQL_BAK", "S1", SQL_bak.IsChecked.GetValueOrDefault().ToString()); //保存的配置
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user