コード例 #1
0
        protected override void CreateTarget()
        {
            m_target = null;

            if (radioButtonCE.Checked)
            {
                if (File.Exists(textBoxSqlCeFile.Text))
                {
                    File.Delete(textBoxSqlCeFile.Text);
                }
                m_target         = MAIDataSinkTarget.CreateTargetSQLCeFile(textBoxSqlCeFile.Text);
                m_TargetFileName = Path.GetFileName(textBoxSqlCeFile.Text) + " (SQLCeFile)";
            }
            else
            {
                DateTime NOW     = DateTime.Now;
                string   MDTable = "MD_" + GetTableNameForNOW(NOW);
                string   CITable = "CI_" + GetTableNameForNOW(NOW);
                CreateConnectionAndDB();
                if (m_conn != null)
                {
                    m_TargetFileName = m_conn.Database + " on " + m_conn.DataSource + " (SQL DB)";
                    m_target         = MAIDataSinkTarget.CreateTargetSQLServer(m_conn, "Measurements", MDTable, CITable, false);
                }
            }
        }
コード例 #2
0
 protected override void CreateTarget()
 {
     m_TargetFileName = Path.GetFileName(textBoxFilenameMain.Text) + " (CSV File)";
     if (checkBoxWriteMeta.Checked)
     {
         m_target = MAIDataSinkTarget.CreateTargetCSV(textBoxFilenameMain.Text, textBoxMetaName.Text, checkBoxAppendTo.Checked, GetSeparatorChar(), GetFormatProvider(), false);
     }
     else
     {
         m_target = MAIDataSinkTarget.CreateTargetCSV(textBoxFilenameMain.Text, checkBoxAppendTo.Checked, GetSeparatorChar(), GetFormatProvider());
     }
 }
コード例 #3
0
 protected override void CreateTarget()
 {
     if (File.Exists(textBoxFilenameMain.Text))
     {
         File.Delete(textBoxFilenameMain.Text);
     }
     if (File.Exists(textBoxFilenameMain.Text + "_index"))
     {
         File.Delete(textBoxFilenameMain.Text + "_index");
     }
     if (File.Exists(textBoxFilenameMain.Text + ".log"))
     {
         File.Delete(textBoxFilenameMain.Text + ".log");
     }
     m_target         = MAIDataSinkTarget.CreateTargetTDMS(Path.GetDirectoryName(textBoxFilenameMain.Text) + "\\" + Path.GetFileNameWithoutExtension(textBoxFilenameMain.Text), textBoxMTitle.Text, textBoxMDesc.Text, textBoxFTitlte.Text, textBoxAuthor.Text);
     m_TargetFileName = Path.GetFileNameWithoutExtension(textBoxFilenameMain.Text) + " (TDMS File)";
 }
コード例 #4
0
 protected override void CreateTarget()
 {
     m_target         = MAIDataSinkTarget.CreateTargetRAW(textBoxFilenameMain.Text);
     m_TargetFileName = Path.GetFileName(textBoxFilenameMain.Text) + " (RAW File)";
 }
コード例 #5
0
 protected override void CreateTarget()
 {
     m_target         = MAIDataSinkTarget.CreateTargetWAV(textBoxFilenameMain.Text, 3434535);
     m_TargetFileName = textBoxFilenameMain.Text + " (WAV Files)";
 }
コード例 #6
0
 protected override void CreateTarget()
 {
     m_target         = MAIDataSinkTarget.CreateTargetTAFFMat(Path.GetDirectoryName(textBoxFilenameMain.Text) + "\\" + Path.GetFileNameWithoutExtension(textBoxFilenameMain.Text));
     m_TargetFileName = Path.GetFileNameWithoutExtension(textBoxFilenameMain.Text) + " (TAFFMAT File)";
 }