private void btnPlayLecture_Click(object sender, EventArgs e) { UpdateLecturePlayButton(); if (imageHolder.Tag == null) { return; } String strAudioName = imageHolder.Tag.ToString(); String strPath = FileUtilities.ExtractDirectoryPath(strAudioName); String strSelectedAudioItem = cmbLectureList.SelectedItem.ToString(); strAudioName = strPath + strSelectedAudioItem; m_objRecordedAudioPlayer = new PTEAudioPlayerWav(strAudioName); m_objRecordedAudioPlayer.PlayAudio(); }
private void buttonPlay_Click(object sender, EventArgs e) { UpdateDescribeImagePlayButton(); if (imageHolder.Tag == null) { return; } String strAudioName = imageHolder.Tag.ToString(); String strPath = FileUtilities.ExtractDirectoryPath(strAudioName); String strSelectedAudioItem = cmbDIRecordings.SelectedItem.ToString(); strAudioName = strPath + strSelectedAudioItem; //double dAudioLength = PTEAudio.GetAudioLength(strAudioName); m_objRecordedAudioPlayer = new PTEAudioPlayerWav(strAudioName); m_objRecordedAudioPlayer.PlayAudio(); }