嘿,亲!知识可是无价之宝呢,但咱这精心整理的资料也耗费了不少心血呀。小小地破费一下,绝对物超所值哦!如有下载和支付问题,请联系我们QQ(微信同号):813200300
本次赞助数额为: 2 元微信扫码支付:2 元
请留下您的邮箱,我们将在2小时内将文件发到您的邮箱
png、jpg、jpeg等多种格式
if (openFileDialog1.ShowDialog() == DialogResult.OK)
{
listView1.Items.Clear();
string[] info = new string[7];
FileInfo fi;
path1 = openFileDialog1.FileNames;
for (int i = 0; i < path1.Length; i )
{
// MessageBox.Show(path1[0]);
//string ImgName = path1[i].Substring(path1[i].LastIndexOf("\\") 1, path1.Length - path1[i].LastIndexOf("\\") - 1);
string ImgName = Path.GetFileNameWithoutExtension(path1[i]);
//string ImgType = ImgName.Substring(ImgName.LastIndexOf(".") 1, ImgName.Length - ImgName.LastIndexOf(".") - 1);
string ImgType = Path.GetExtension(path1[i]);
fi = new FileInfo(path1[i].ToString());
//imageList1.Images.Add(ImgName,Properties.Resources.图标__23_);
info[1] = ImgName;
info[2] = ImgType;
info[3] = fi.LastWriteTime.ToShortDateString();
info[4] = path1[i].ToString();
info[5] = (fi.Length / 1024) "KB";
info[6] = "未转换";
//ListViewItem lvi = new ListViewItem(info,ImgName);
for (int j = 1; j <= 6; j )
{
listView1.Items.Add(info[j]);
}
}
toolStripStatusLabel1.Text = "当前共有" path1.Length.ToString() "个文件";
}