Exemple #1
0
        private void btn_SaveSocketPara_Click(object sender, EventArgs e)
        {
            Class_IniOperation _iniOperation = new Class_IniOperation(Class_Global.SocketParaPath);

            _iniOperation.WriteValue("Socket", "IP", txB_IP.Text);
            _iniOperation.WriteValue("Socket", "Port", txB_SocketPort.Text);
        }
Exemple #2
0
        private void btnsavecommmunication_Click(object sender, EventArgs e)
        {
            Class_IniOperation _iniOperation = new Class_IniOperation(Class_Global.SocketParaPath);

            _iniOperation.WriteValue("Socket", "IP", text_IP.Text);
            _iniOperation.WriteValue("Socket", "Port", text_Port.Text);
        }
Exemple #3
0
        //类的构造函数
        public IniFileData(string path)
        {
            _comPort  = new ComPortSection();
            _ethernet = new EthernetSection();

            _path         = path;
            _iniOperation = new Class_IniOperation(path);
        }
Exemple #4
0
        private void checkBox_IsSocketOpen_Click(object sender, EventArgs e)
        {
            Class_IniOperation _iniOperation = new Class_IniOperation(Class_Global.SocketParaPath);

            if (checkBox_IsSocketOpen.Checked == true)
            {
                _iniOperation.WriteValue("Socket", "开关", "打开");
            }
            else
            {
                _iniOperation.WriteValue("Socket", "开关", "关闭");
            }
        }