- Home /
Question by
Thriliriel · May 31, 2020 at 05:03 PM ·
buildvoice
SpeechLib works fine in editor but not in runtime
Hey there.
I am trying to use SpeechLib to implement Text-To-Speech in Unity, it works fine in the editor but I get an exception when running a build on windows. Here is the error:
NotSupportedException: Specified method is not supported. at System.__ComObject..ctor () [0x00006] in :0 at (wrapper cominterop) SpeechLib.SpVoiceClass..ctor()
Does anyone know how to fix it?
Thanks in advance!
Comment
Best Answer
Answer by ShadyBoshra2012 · Jun 12, 2020 at 11:48 AM
I found the solution.
Steps:
Build Settings
Player Settings
Make sure you selected "Standalone" tab
Open "Other Settings" tab
Api Compatibility Level: choose .Net 4.x
Save and build
Your answer
![](https://koobas.hobune.stream/wayback/20220612235741im_/https://answers.unity.com/themes/thub/images/avi.jpg)