Example #1
0
        private bool DataFileLoad()
        {
            string strFilePath;

            strFilePath = Application.StartupPath + "\\Data";
            DataList.Clear();
            if (System.IO.Directory.Exists(strFilePath))
            {
                System.IO.DirectoryInfo direc = new System.IO.DirectoryInfo(strFilePath);

                foreach (var fileItem in direc.GetFiles())
                {
                    VSRData AddVSRData = new VSRData();
                    // ini 확장자가 아닌 파일들 걸러 주기
                    if (fileItem.Name.IndexOf(".ini") == -1 || fileItem.Name.IndexOf("VendorName") != -1)
                    {
                        continue;
                    }
                    AddVSRData.LoadDataToFile(strFilePath + "\\" + fileItem.Name);
                    DataList.Add(AddVSRData);
                }
            }

            return(true);
        }
Example #2
0
 private void button_Modify_Click(object sender, EventArgs e)
 {
     if (PrjListView.SelectedItems.Count > 0)
     {
         string  strTemp         = PrjListView.FocusedItem.ToString();
         VSRData m_cSelectedData = new VSRData();
         m_cSelectedData.SetFileName(strTemp);
         int nSelectIndex = -1;
         nSelectIndex = PrjListView.FocusedItem.Index;
         if (nSelectIndex != -1 && strTemp != "")
         {
             m_cSelectedData = DataList[nSelectIndex];
             AddPrjForm addDlg = new AddPrjForm(m_cSelectedData);
             addDlg.SendAddResultEvent += new AddPrjForm.SendAddResult(GetAddResult);
             addDlg.ShowDialog();
             DataFileSave();
         }
     }
 }
Example #3
0
        private void PrjListView_DoubleClick(object sender, EventArgs e)
        {
            int nSelectIndex = PrjListView.FocusedItem.Index;

            if (nSelectIndex != -1)
            {
                string  strTemp         = PrjListView.FocusedItem.ToString();
                VSRData m_cSelectedData = new VSRData();
                m_cSelectedData.SetFileName(strTemp);
                if (strTemp != "")
                {
                    m_cSelectedData = DataList[nSelectIndex];
                    AddPrjForm addDlg = new AddPrjForm(m_cSelectedData);
                    addDlg.SendAddResultEvent += new AddPrjForm.SendAddResult(GetAddResult);
                    addDlg.ShowDialog();
                    DataFileSave();
                }
                DataFileLoad();
                initAllListViews();
                PrintProjectToListBox();
            }
        }
Example #4
0
        private void PrjListView_Click(object sender, EventArgs e)
        {
            int nSelectIndex = -1;

            nSelectIndex = PrjListView.FocusedItem.Index;
            string strSelected;


            ClearTextBoxes();
            if (nSelectIndex != -1)
            {
                strSelected = PrjListView.FocusedItem.ToString();
                m_cSelectedData.SetFileName(strSelected);
                m_cSelectedData = DataList[nSelectIndex];
                PrintItemToListView(m_cSelectedData.SensorList, SensorListView);
                PrintItemToListView(m_cSelectedData.PartsList, ConfigListView);
                PrintItemToListView(m_cSelectedData.IRCFList, IRCFListView);
                PrintItemToListView(m_cSelectedData.LensList, LensListView);
                PrintItemToListView(m_cSelectedData.StiffenerList, StiffenerListView);
                PrintItemToListView(m_cSelectedData.SubstrateList, SubstrateListView);
                PrintItemToListView(m_cSelectedData.FlexList, FlexListView);
                PrintItemToListView(m_cSelectedData.CarrierList, CarrierListView);
                PrintItemToListView(m_cSelectedData.CameraBuildList, BuildListView);
                PrintEEEEToTextBox(m_cSelectedData);

                PrjTextBox.Text           = PrjListView.FocusedItem.SubItems[1].Text;
                m_cRefData.m_strPrjName   = PrjListView.FocusedItem.SubItems[1].Text;
                m_cRefData.NVM            = m_cSelectedData.NVMList[0];
                m_cRefData.CameraPrj      = m_cSelectedData.CameraPrjList[0];
                m_cRefData.ProgramVariant = m_cSelectedData.ProgramVariantList[0];
                m_cRefData.Intergrator    = m_cSelectedData.IntegratorList[0];
                m_cRefData.SoftWare       = m_cSelectedData.AlgorithmList[0];
                m_cRefData.ColorShading   = m_cSelectedData.ColorShadingList[0];
                m_cRefData.Traceability   = m_cSelectedData.TraceabilityRevList[0];
            }
        }
Example #5
0
 void GetAddResult(bool inResult, VSRData inAddVSR)
 {
     m_AddVSR     = inAddVSR;
     m_bAddResult = inResult;
 }
Example #6
0
 private void PrintEEEEToTextBox(VSRData inData)
 {
     EEEETextBox.Clear();
     EEEETextBox.Text = inData.m_strEEEE;
 }