look at how key 2 & 3 are setup and understand the logic pattern and apply it to the…
- User
look at how key 2 & 3 are setup and understand the logic pattern and apply it to the rest of the voids.
private void Key_2_Click(object sender, EventArgs e) { try { if (!Directory.Exists(LocationKey)) { Directory.CreateDirectory(LocationKey); }
if (File.Exists(LocationKey + @"\Slash.wav")) { File.Delete(LocationKey + @"\Slash.wav"); File.Copy(audioFilePath, LocationKey + @"\Slash.wav", true); KeyStrings[1] = LocationKey + @"\Slash.wav"; Key_2_SLASH.ForeColor = Color.Red; } else { File.Copy(audioFilePath, LocationKey + @"\Slash.wav", true); KeyStrings[1] = LocationKey + @"\Slash.wav"; Key_2_SLASH.ForeColor = Color.Red; } LookButton.Focus(); LookButton.Select(); } catch { }}
private void Key_3_Click(object sender, EventArgs e) { try { if (!Directory.Exists(LocationKey)) { Directory.CreateDirectory(LocationKey); }
if (File.Exists(LocationKey + @"\Multiply.wav")) { File.Delete(LocationKey + @"\Multiply.wav"); File.Copy(audioFilePath, LocationKey + @"\Multiply.wav", true); KeyStrings[2] = LocationKey + @"\Multiply.wav"; Key_3_MULTI.ForeColor = Color.Red; } else { File.Copy(audioFilePath, LocationKey + @"\Multiply.wav", true); KeyStrings[2] = LocationKey + @"\Multiply.wav"; Key_3_MULTI.ForeColor = Color.Red; } LookButton.Focus(); LookButton.Select(); } catch { }}
private void Key_4_Click(object sender, EventArgs e) { if (!Directory.Exists(LocationKey)) { Directory.CreateDirectory(LocationKey); }
Key_4_MIN.ForeColor = Color.Red; KeyStrings[3] = audioFilePath; File.Copy(audioFilePath, LocationKey + @"\Subtract.wav", true); KeyStrings[3] = LocationKey + @"\Subtract.wav"; LookButton.Focus(); LookButton.Select();}
private void Key_5_Click(object sender, EventArgs e) { if (!Directory.Exists(LocationKey)) { Directory.CreateDirectory(LocationKey); }
Key_5_SEVEN.ForeColor = Color.Red; KeyStrings[4] = audioFilePath; File.Copy(audioFilePath, LocationKey + @"\Seven.wav", true); KeyStrings[4] = LocationKey + @"\Seven.wav"; LookButton.Focus(); LookButton.Select();}
private void Key_6_Click(object sender, EventArgs e) { if (!Directory.Exists(LocationKey)) { Directory.CreateDirectory(LocationKey); }
Key_6_EIGHT.ForeColor = Color.Red; KeyStrings[5] = audioFilePath; File.Copy(audioFilePath, LocationKey + @"\Eight.wav", true); KeyStrings[5] = LocationKey + @"\Eight.wav"; LookButton.Focus(); LookButton.Select();}
private void Key_7_Click(object sender, EventArgs e) { if (!Directory.Exists(LocationKey)) { Directory.CreateDirectory(LocationKey); }
Key_7_NINE.ForeColor = Color.Red; KeyStrings[6] = audioFilePath; File.Copy(audioFilePath, LocationKey + @"\Nine.wav", true); KeyStrings[6] = LocationKey + @"\Nine.wav"; LookButton.Focus(); LookButton.Select(); - Assistant
- User
add key 2 and 3 you forgot them.
- Assistant