예제 #1
0
 private void 卸载V盘ToolStripMenuItem_Click(object sender, EventArgs e)
 {
     VHDOperation vo = new VHDOperation();
     vo.DetachVHD();
 }
예제 #2
0
 private void 修复盘符ToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if (comboBox1.SelectedIndex == 0) { MessageBox.Show(MsgManager.GetResString("Msg_chooseud", MsgManager.ci)); return; }
     WTGOperation.ud = comboBox1.SelectedItem.ToString().Substring(0, 2) + "\\";//优盘
     string vhdPath = string.Empty;
     if (File.Exists(vhdPath = WTGOperation.ud + "win8.vhd") || File.Exists(vhdPath = WTGOperation.ud + "win8.vhdx"))
     {
         VHDOperation vo = new VHDOperation();
         vo.AttachVHD(vhdPath);
         ImageOperation.Fixletter("C:", "V:");
         vo.DetachVHD();
     }
     else
     {
         ImageOperation.Fixletter("C:", WTGOperation.ud.Substring(0, 2));
     }
     MessageBox.Show(MsgManager.GetResString("Msg_Complete", MsgManager.ci));
 }