Exemplo n.º 1
0
        private void btnSave_Click(object sender, EventArgs e)
        {
            IniFiles fop = new IniFiles("Settings.ini");
            QWriteAllForm.TestList.Clear(); // clear old data

            if (checkBoxTest.Checked)
                QWriteAllForm.TestList.Add("TestBoard");          
            if (checkBoxSN.Checked)
                QWriteAllForm.TestList.Add("SN");
            if (checkBoxBTMAC.Checked) 
                QWriteAllForm.TestList.Add("BTMAC");
            if (checkBoxWIFIMAC.Checked)
                QWriteAllForm.TestList.Add("WIFIMAC");
            if (checkBoxNv453.Checked)
                QWriteAllForm.TestList.Add("NV453");
            
            /*save configuration to file*/
            fop.WriteBool("TEST", "TestBoard", checkBoxTest.Checked);
            fop.WriteBool("TEST", "SN", checkBoxSN.Checked);
            fop.WriteBool("TEST", "BTMAC", checkBoxBTMAC.Checked);
            fop.WriteBool("TEST", "WIFIMAC", checkBoxWIFIMAC.Checked);
            fop.WriteBool("TEST", "NV453", checkBoxNv453.Checked);
            fop.WriteString("TEST", "WLANADDR", WlantextBox.Text);
            fop.WriteString("TEST", "BTADDR", BttextBox.Text);
            fop.WriteString("TEST", "SNHEADER", snHeaderBox.Text);
            // check test item count 
            if (QWriteAllForm.TestList.Count < 1)
            {
                MessageBox.Show("Please Add test Item!");
                return;
            }
            this.DialogResult = DialogResult.OK;//DialogResult
            this.Close();            
        }
Exemplo n.º 2
0
 private void pcbapowersaveBtn_Click(object sender, EventArgs e)
 {
     /*save to file*/
     IniFiles fop = new IniFiles("Settings.ini");
     fop.WriteString("PCBAPOWER", "LEAKCURRENT", pcbaleakBox.Text);
     fop.WriteString("PCBAPOWER", "SLEEPCURRENT",pcbasleepBox.Text);
     this.Close();
 }
Exemplo n.º 3
0
 private void wholepowersaveBtn_Click(object sender, EventArgs e)
 {
     IniFiles fop = new IniFiles("Settings.ini");
     fop.WriteString("DEVICEPOWER", "LEAKCURRENT", leakcurBox.Text);
     fop.WriteString("DEVICEPOWER", "SLEEPCURRENT", sleepcurBox.Text);
     fop.WriteString("DEVICEPOWER", "STABLECURRENT", stablecurBox.Text);
     fop.WriteBool("DEVICEPOWER", "MMI", entermmicheckBox.Checked);
     this.Close();
 }
Exemplo n.º 4
0
 private void SaveParameterToFile()
 {
     IniFiles Fop = new IniFiles("Settings.ini");
     Fop.WriteString("DOWNLOAD", "Chip", QSWDownloadForm.swInfo.ProName);
     Fop.WriteString("DOWNLOAD", "Mode", QSWDownloadForm.swInfo.SwType);
     Fop.WriteString("DOWNLOAD", "Path", QSWDownloadForm.swInfo.ProgramPath);
     Fop.WriteString("DOWNLOAD", "Programmer", QSWDownloadForm.swInfo.MbnName);
     Fop.WriteString("DOWNLOAD", "RawName", QSWDownloadForm.swInfo.RawProName);
     Fop.WriteString("DOWNLOAD", "Patch0", QSWDownloadForm.swInfo.PathName);
 }