private void buttonSaveDecoded_Click(object sender, EventArgs e) { string outputPath = $"{encodedFilePath}.bmp"; using (var imageWriter = new ImageWriter()) { imageWriter.SaveImage(decodedBitmap, encodedFilePath, outputPath); } this.toolStripStatusLabel.Text = "File saved"; }