Ejemplo n.º 1
0
        private void SaveIni(string path)
        {
            if (!Directory.Exists(path))
            {
                Directory.CreateDirectory(path);
            }

            Ini ini = new Ini(string.Format(@"{0}\{1}", path, "env.ini"));

            ini.IniWriteValue("PBX", "IP", txtIpAddr.Text.Trim());
            ini.IniWriteValue("PBX", "PORT", txtPort.Text.Trim());
            ini.IniWriteValue("ETC", "STARTPOPUP", chbPopup.IsChecked.ToString());
        }
Ejemplo n.º 2
0
        private void SaveIni()
        {
            Ini ini = new Ini(string.Format(@"{0}\{1}", userdatapath, "pms.ini"));

            ini.IniWriteValue("POSITION", "WIDTH", this.Width.ToString());
            ini.IniWriteValue("POSITION", "HEIGHT", this.Height.ToString());
            ini.IniWriteValue("POSITION", "LEFT", this.Left.ToString());
            ini.IniWriteValue("POSITION", "TOP", this.Top.ToString());

            ini.IniWriteValue("PBX", "IP", util.PBXIP);
            ini.IniWriteValue("DB", "IP", util.DBIP);
            ini.IniWriteValue("DB", "FILEPATH", util.DBPATH);
        }
Ejemplo n.º 3
0
        private void SaveIni(string path)
        {
            if (!Directory.Exists(path))
                Directory.CreateDirectory(path);

            Ini ini = new Ini(string.Format(@"{0}\{1}", path, "env.ini"));

            ini.IniWriteValue("PBX", "IP", txtIPAddress.Text.Trim());
            ini.IniWriteValue("PBX", "PORT", txtPort.Text.Trim());

            CoupleModeInfo.pbxipaddress = txtIPAddress.Text.Trim();
            CoupleModeInfo.pbxport = string.IsNullOrEmpty(txtPort.Text.Trim()) == false ? int.Parse(txtPort.Text.Trim()) : 31001;
        }
Ejemplo n.º 4
0
        private void SavePosition()
        {
            Ini ini = new Ini(@".\pms.ini");
            ini.IniWriteValue("POSITION", "WIDTH", this.Width.ToString());
            ini.IniWriteValue("POSITION", "HEIGHT", this.Height.ToString());
            ini.IniWriteValue("POSITION", "LEFT", this.Left.ToString());
            ini.IniWriteValue("POSITION", "TOP", this.Top.ToString());

            ini.IniWriteValue("SERVER", "PBXIP", util.PBXIP);
            ini.IniWriteValue("SERVER", "DBIP", util.DBIP);
        }
Ejemplo n.º 5
0
        private void flyoutOptions_IsVisibleChanged(object sender, DependencyPropertyChangedEventArgs e)
        {
            var obj = (Flyout)sender;

            if (obj.IsOpen)
            {
                if (tabFloor.IsEnabled)
                    tabFloor.IsEnabled = false;

                //list_floors = new FloorRs();
                //list_floors.CollectionChanged += list_floors_CollectionChanged;
                //options_floors.ItemsSource = list_floors;

                pbxip.Text = util.PBXIP;
                dbip.Text = util.DBIP;
            }
            else
            {
                int count = 0;
                foreach (Flyout item in this.Flyouts.Items)
                {
                    if (item.IsVisible)
                        count++;
                }

                if (count < 1)
                    tabFloor.IsEnabled = true;

                //options_floors.ItemsSource = null;
                //options_rooms.ItemsSource = null;
                //options_tels.ItemsSource = null;

                util.PBXIP = pbxip.Text.Trim();
                util.DBIP = dbip.Text.Trim();

                Ini ini = new Ini(@".\pms.ini");
                ini.IniWriteValue("SERVER", "PBXIP", util.PBXIP);
                ini.IniWriteValue("SERVER", "DBIP", util.DBIP);
            }
        }
Ejemplo n.º 6
0
 public void SaveProps()
 {
     Ini ini = new Ini(@".\cdr.ini");
     ini.IniWriteValue("ETC", "RUNSTART", _runstart.ToString());
 }
Ejemplo n.º 7
0
        private void SaveIni()
        {
            Ini ini = new Ini(string.Format(@"{0}\{1}", userdatapath, "env.ini"));

            ini.IniWriteValue("MAIN", "TOP", this.Top.ToString());
            ini.IniWriteValue("MAIN", "LEFT", this.Left.ToString());
        }
Ejemplo n.º 8
0
        public void SaveIni()
        {
            Ini ini = new Ini(string.Format(@"{0}\{1}", userdatapath, "env.ini"));

            ini.IniWriteValue("PHONEBOOK", "TOP", this.Top.ToString());
            ini.IniWriteValue("PHONEBOOK", "LEFT", this.Left.ToString());
            ini.IniWriteValue("PHONEBOOK", "WIDTH", this.Width.ToString());
            ini.IniWriteValue("PHONEBOOK", "HEIGHT", this.Height.ToString());
        }
Ejemplo n.º 9
0
        private void SaveIni(string path)
        {
            Ini ini = new Ini(string.Format(@"{0}\{1}", path, "env.ini"));

            if (chksaveid.IsChecked == true ? true : false) ini.IniWriteValue("LOGON", "ID", txtid.Text);
            ini.IniWriteValue("LOGON", "SAVEID", chksaveid.IsChecked.ToString());
            ini.IniWriteValue("LOGON", "AUTOLOGON", chkautologon.IsChecked.ToString());
            ini.IniWriteValue("LOGON", "TOP", this.Top.ToString());
            ini.IniWriteValue("LOGON", "LEFT", this.Left.ToString());
        }
Ejemplo n.º 10
0
 private void WriteIni()
 {
     Ini inifile = new Ini(inifilepath);
     inifile.IniWriteValue("POSITION", "TOP", this.Top.ToString());
     inifile.IniWriteValue("POSITION", "LEFT", this.Left.ToString());
     inifile.IniWriteValue("SIZE", "WIDTH", this.Width.ToString());
     inifile.IniWriteValue("SIZE", "HEIGHT", this.Height.ToString());
     inifile.IniWriteValue("ETC", "STATE", this.WindowState.ToString());
 }