添加项目文件。
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
using MetroFramework.Forms;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
using JY.Inspection.Common;
|
||||
using JY.Utility;
|
||||
|
||||
namespace JY.Inspection.Frm
|
||||
{
|
||||
public partial class FrmDBbaseSet : MetroForm
|
||||
{
|
||||
public FrmDBbaseSet()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
private void FrmDBbaseSet_Load(object sender, EventArgs e)
|
||||
{
|
||||
txtDBIP.Text = IniFileHelper.ReadIniData("MYSQL配置", "DB_IP");
|
||||
txtDBName.Text = IniFileHelper.ReadIniData("MYSQL配置", "DB_Name");
|
||||
txtDBUser.Text = IniFileHelper.ReadIniData("MYSQL配置", "DB_User");
|
||||
txtDBPwd.Text = IniFileHelper.ReadIniData("MYSQL配置", "DB_Pwd");
|
||||
|
||||
}
|
||||
|
||||
private void btnSave_Click(object sender, EventArgs e)
|
||||
{
|
||||
IniFileHelper.WriteIniData("MYSQL配置", "DB_IP", txtDBIP.Text.Trim());
|
||||
IniFileHelper.WriteIniData("MYSQL配置", "DB_Name", txtDBName.Text.Trim());
|
||||
IniFileHelper.WriteIniData("MYSQL配置", "DB_User", txtDBUser.Text.Trim());
|
||||
IniFileHelper.WriteIniData("MYSQL配置", "DB_Pwd", txtDBPwd.Text.Trim());
|
||||
|
||||
MessageBox.Show("数据库参数保存成功!", "系统提示");
|
||||
}
|
||||
|
||||
private void btnExit_Click(object sender, EventArgs e)
|
||||
{
|
||||
this.Close();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user