C# 加密解密 将自己的文件加密

时间:2021-09-13 04:41:22
【文件属性】:

文件名称:C# 加密解密 将自己的文件加密

文件大小:89KB

文件格式:ZIP

更新时间:2021-09-13 04:41:22

C# 加密 解密

C# 加密解密 将自己的文件加密 //选择加密、解密文件 private void button1_Click(object sender, EventArgs e) { if (openFileDialog1.ShowDialog() == DialogResult.OK) { textBox1.Text = openFileDialog1.FileName; FileInfo FInfo = new FileInfo(textBox1.Text); if (FInfo.Extension.ToLower() == ".mr") { button2.Enabled = false; button3.Enabled = true; } else { button2.Enabled = true; button3.Enabled = false; } } } //加密 private void button2_Click(object sender, EventArgs e) { if (textBox1.Text != "") { if (textBox2.Text.Length < 6) MessageBox.Show("密码不能小于6位!", "警告", MessageBoxButtons.OK, MessageBoxIcon.Warning); else { EDncrypt myEDncrypt = new EDncrypt(textBox1.Text, textBox2.Text, progressBar1); myEDncrypt.StartEncrypt(); progressBar1.Value = 0; } } }


【文件预览】:
文件加密
----Backup()
--------ProtectFile()
--------ProtectFile.sln(923B)
----ProtectFile()
--------Form1.Designer.cs(8KB)
--------Program.cs(492B)
--------obj()
--------bin()
--------Form1.cs(11KB)
--------加密.ico(766B)
--------Form1.resx(6KB)
--------Properties()
--------ProtectFile.csproj(4KB)
----ProtectFile.sln(1000B)
----ProtectFile.suo(20KB)
----.vs()
--------ProtectFile()
----UpgradeLog.htm(41KB)

网友评论