private void Button17_Click(object sender, System.EventArgs e) { if (MessageBox.Show("This can take some time! Continue ?", "Detecting BPM", MessageBoxButtons.YesNoCancel) == System.Windows.Forms.DialogResult.Yes) { int BPM = 0; BPM = player.DetectBPM(TBPMDetectionMethod.dmPeaks); MessageBox.Show("BPM: " + System.Convert.ToString(BPM), "Detected BPM", MessageBoxButtons.OK); } }