Пример #1
0
        private void MenuAdd_Click(object sender, EventArgs e)
        {
            OpenFileDialog ofd = new OpenFileDialog();

            ofd.Filter          = "cvn 파일(*.cv*)|*.cv*|모든 파일(*.*)|*.*";
            ofd.FilterIndex     = 1;
            ofd.CheckFileExists = ofd.CheckPathExists = true;
            ofd.Multiselect     = true;

            if (ofd.ShowDialog() == DialogResult.OK)
            {
                foreach (string file_name in ofd.FileNames)
                {
                    frmEntryName dlgName = new frmEntryName();
                    dlgName.Top   = this.Top + 50;
                    dlgName.Left  = this.Left + 50;
                    dlgName.Entry = file_name;
                    dlgName.ShowDialog();
                    if (dlgName.Entry == string.Empty)
                    {
                        return;
                    }
                    TenshiEntry i = new TenshiEntry(null, dlgName.Entry, 0, 0);
                    i.ChangedStream = File.OpenRead(file_name);
                    m_workingfile.Entries.Add(i);
                    AddNode(i);
                }
            }
        }
Пример #2
0
        private void MenuAdd_Click(object sender, EventArgs e)
        {
            OpenFileDialog ofd = new OpenFileDialog();
            ofd.Filter = "cvn 파일(*.cv*)|*.cv*|모든 파일(*.*)|*.*";
            ofd.FilterIndex = 1;
            ofd.CheckFileExists = ofd.CheckPathExists = true;
            ofd.Multiselect = true;

            if (ofd.ShowDialog() == DialogResult.OK)
            {
                foreach (string file_name in ofd.FileNames)
                {
                    frmEntryName dlgName = new frmEntryName();
                    dlgName.Top = this.Top + 50;
                    dlgName.Left = this.Left + 50;
                    dlgName.Entry = file_name;
                    dlgName.ShowDialog();
                    if (dlgName.Entry == string.Empty) return;
                    TenshiEntry i = new TenshiEntry(null, dlgName.Entry, 0, 0);
                    i.ChangedStream = File.OpenRead(file_name);
                    m_workingfile.Entries.Add(i);
                    AddNode(i);
                }
            }
        }