OpenFileDialog openFileDialog = new OpenFileDialog(); openFileDialog.Title = " 请选择您要导入的模板文件:"; openFileDialog.Filter = "TextDocument(*.txt)|*.txt|TextDocument(*.ini)|*.ini"; openFileDialog.ShowDialog(); if (openFileDialog.FileName != "")//判断文件名是否为空 { StreamReader streamReader = new StreamReader(openFileDialog.FileName, Encoding.Default); this.txtextBox.Text = streamReader.ReadToEnd(); }
- 随机文章
- 热门文章
- 热评文章
- 树莓花生壳内网映射官方教程失败解决
- kali2.0安装完成后全是乱码解决办法
- labVIEW调用C# dll 步骤
- C#图像处理(各种旋转、改变大小、柔化、锐化、雾化、底片、浮雕、黑白、滤镜效果)
- 安装包制作工具 SetupFactory使用1 详解
- C#中的MessageBox消息对话框
- 永恒之蓝病毒是什么 怎么防范ONION勒索软件
- C#修改图片分辨率