8 changed files with 136 additions and 14 deletions
@ -0,0 +1,13 @@ |
|||||
|
<Window x:Class="formula_manage.Windows.APP_set" |
||||
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" |
||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
||||
|
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" Loaded="Window_SET" |
||||
|
Title="APP_set" Height="450" Width="800"> |
||||
|
<Grid> |
||||
|
<CheckBox x:Name="Login_LINK" Height="19" Margin="15,15,605,0" VerticalAlignment="Top" Content="登录页面显示连接状态" IsTabStop="False" Checked="Login_LINK_Checked" Unchecked="Login_LINK_Checked"/> |
||||
|
|
||||
|
</Grid> |
||||
|
</Window> |
||||
@ -0,0 +1,45 @@ |
|||||
|
using System; |
||||
|
using System.Collections.Generic; |
||||
|
using System.Linq; |
||||
|
using System.Text; |
||||
|
using System.Threading.Tasks; |
||||
|
using System.Windows; |
||||
|
using System.Windows.Controls; |
||||
|
using System.Windows.Data; |
||||
|
using System.Windows.Documents; |
||||
|
using System.Windows.Input; |
||||
|
using System.Windows.Media; |
||||
|
using System.Windows.Media.Imaging; |
||||
|
using System.Windows.Shapes; |
||||
|
|
||||
|
namespace formula_manage.Windows |
||||
|
{ |
||||
|
/// <summary>
|
||||
|
/// APP_set.xaml 的交互逻辑
|
||||
|
/// </summary>
|
||||
|
public partial class APP_set : Window |
||||
|
{ |
||||
|
public APP_set() |
||||
|
{ |
||||
|
WindowStartupLocation = WindowStartupLocation.CenterScreen; |
||||
|
InitializeComponent(); |
||||
|
} |
||||
|
public string INIPath = Convert.ToString(System.AppDomain.CurrentDomain.BaseDirectory) + "formula.ini"; |
||||
|
|
||||
|
bool Login_link; |
||||
|
private void Window_SET(object sender, RoutedEventArgs e) |
||||
|
{ |
||||
|
|
||||
|
UserClass.IniFile.IniFiles Configini = new UserClass.IniFile.IniFiles(INIPath); |
||||
|
|
||||
|
Login_link = Boolean.Parse(Configini.IniReadvalue("SOFTWARE_SET", "L1")); //连接状态显示是否生效
|
||||
|
|
||||
|
} |
||||
|
private void Login_LINK_Checked(object sender, RoutedEventArgs e) |
||||
|
{ |
||||
|
Login_link = Login_LINK.IsChecked.GetValueOrDefault(); //显示是否生效
|
||||
|
UserClass.IniFile.IniFiles Configini = new UserClass.IniFile.IniFiles(INIPath); //配置文件
|
||||
|
Configini.IniWritevalue("SOFTWARE_SET", " L1", Login_link.ToString()); |
||||
|
} |
||||
|
} |
||||
|
} |
||||
Loading…
Reference in new issue