コード例 #1
0
        private void btnImport_Click(object sender, RoutedEventArgs e)
        {
            if (this._id < 1)
            {
                SaveItem();
            }

            // Create OpenFileDialog
            Microsoft.Win32.OpenFileDialog dlg = new Microsoft.Win32.OpenFileDialog();

            // Set filter for file extension and default file extension
            dlg.DefaultExt = ".csv";
            dlg.Filter     = "csv documents (.csv)|*.csv";

            // Display OpenFileDialog by calling ShowDialog method
            Nullable <bool> result = dlg.ShowDialog();

            // Get the selected file name and display in a TextBox
            if (result == true)
            {
                // Open document
                string           filename = dlg.FileName;
                SpareIncomeSmart v        = new SpareIncomeSmart(this._id, filename);
                v.ShowDialog();
                LoadOfferings();
            }
        }
コード例 #2
0
        private void btnSmartIncome_Click(object sender, RoutedEventArgs e)
        {
            if (this._id < 1)
            {
                SaveItem();
            }

            SpareIncomeSmart v = new SpareIncomeSmart(this._id);

            v.ShowDialog();
            LoadOfferings();
        }
コード例 #3
0
        private void btnSmartIncome_Click(object sender, RoutedEventArgs e)
        {
            if (this._id < 1)
                SaveItem();

            SpareIncomeSmart v = new SpareIncomeSmart(this._id);
            v.ShowDialog();
            LoadOfferings();
        }
コード例 #4
0
        private void btnImport_Click(object sender, RoutedEventArgs e)
        {
            if (this._id < 1)
                SaveItem();

            // Create OpenFileDialog
            Microsoft.Win32.OpenFileDialog dlg = new Microsoft.Win32.OpenFileDialog();

            // Set filter for file extension and default file extension
            dlg.DefaultExt = ".csv";
            dlg.Filter = "csv documents (.csv)|*.csv";

            // Display OpenFileDialog by calling ShowDialog method
            Nullable<bool> result = dlg.ShowDialog();

            // Get the selected file name and display in a TextBox
            if (result == true)
            {
                // Open document
                string filename = dlg.FileName;
                SpareIncomeSmart v = new SpareIncomeSmart(this._id, filename);
                v.ShowDialog();
                LoadOfferings();
            }
        }