public static IDataSinkTarget ShowAsDialog(string AIMenuText, out string AOString)
        {
            FormDSTargetConfigBase dts = null;
            AOString = "not set.";

            if (AIMenuText.StartsWith("CSV"))
                dts = new FormDSTargetCSV();
            if (AIMenuText.StartsWith("RAW"))
                dts = new FormDSTargetRAW();
            if (AIMenuText.StartsWith("TDMS"))
                dts = new FormDSTargetTDMS();
            if (AIMenuText.StartsWith("TAFF"))
                dts = new FormDSTargetTAFFMAT();
            if (AIMenuText.StartsWith("Database"))
                dts = new FormDSTargetDB();
            if (AIMenuText.StartsWith("WAV"))
                dts = new FormDSTargetWAV();
            if (dts == null) {
                return null;
            }
            if (dts.ShowDialog() == DialogResult.OK) {
                AOString = dts.m_TargetFileName;
                return dts.m_target;
            }
            return null;
        }
Exemple #2
0
        public static IDataSinkTarget ShowAsDialog(string AIMenuText, out string AOString)
        {
            FormDSTargetConfigBase dts = null;

            AOString = "not set.";

            if (AIMenuText.StartsWith("CSV"))
            {
                dts = new FormDSTargetCSV();
            }
            if (AIMenuText.StartsWith("RAW"))
            {
                dts = new FormDSTargetRAW();
            }
            if (AIMenuText.StartsWith("TDMS"))
            {
                dts = new FormDSTargetTDMS();
            }
            if (AIMenuText.StartsWith("TAFF"))
            {
                dts = new FormDSTargetTAFFMAT();
            }
            if (AIMenuText.StartsWith("Database"))
            {
                dts = new FormDSTargetDB();
            }
            if (AIMenuText.StartsWith("WAV"))
            {
                dts = new FormDSTargetWAV();
            }
            if (dts == null)
            {
                return(null);
            }
            if (dts.ShowDialog() == DialogResult.OK)
            {
                AOString = dts.m_TargetFileName;
                return(dts.m_target);
            }
            return(null);
        }