フィルターのクリア

GUI .exe doesn't work fully, while the .m file has no problems.

2 ビュー (過去 30 日間)
david gold
david gold 2014 年 7 月 15 日
コメント済み: david gold 2014 年 7 月 17 日
Hello,
I wrote a GUI in Matlab 2013a which uses the Data Acquisition Toolbox. One of the functions of this GUI is to record sound using the laptop/PC microphone ('winsound') or a NIDAQ USB 6008.
I'm trying to run the .exe on a PC which doesn't have Matlab installed (by installing the matlab runtime 8.1), but one of the functions (the function which records sound) doesn't work. I have no idea why.
BTW, if I install Matlab on the PC of interest, it works. Very strange. When I remove Matlab from the PC, the problem occurs again.
I took a screenshot of the command prompt and the error which is displayed:
The error happens only when I press the 'Start recording' push button. All the other functions/buttons etc. work fine.
Does anybody have an idea why this is happening?
David.

採用された回答

Mukul Rao
Mukul Rao 2014 年 7 月 15 日
編集済み: Mukul Rao 2014 年 7 月 15 日
Hi,
I think the reason why the application you built is not functioning on a PC without MATLAB is because the Matlab Runtime is unable to locate the dynamic library file “mwwinsound.dll” . I would suggest running your application after copying this .dll file to your application directory.
You can also rebuild your app after including commands like
>> daqregister('winsound');
>> daqhwinfo
These commands would let you know if the windows sound card is being successfully detected by the MCR.
  1 件のコメント
david gold
david gold 2014 年 7 月 17 日
Thank you very much. I entered these lines into the code and matlab told me that I don't have full administrator rights to register the winsound adapter.
I ran the .exe as administrator and it worked.
Thank you again!

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeAudio I/O and Waveform Generation についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by