////////选取目录
string debugPath = null;
            // 选取目录
            FolderBrowserDialog fbd = new FolderBrowserDialog();
            fbd.ShowDialog();
            debugPath = fbd.SelectedPath;   



/////////选取文件
 OpenFileDialog ofd = new OpenFileDialog();
            ofd.ShowDialog();
          string  xmlPath = ofd.FileName;    //路径
            string fileName = Path.GetFileName(xmlPath);//文件名
            //  MessageBox.Show(fileName); 

 

posted on 2015-08-20 15:36  艾伦_彡  阅读(490)  评论(0)    收藏  举报