How do I get C# to recognize system.speech namespace?
-
2009年7月8日 18:29So I have Vista and have installed speech recognition and I can't get C# to recognize it's there. It flags it as wrong in the code editor saying it does not know of a namespace by that name. Any suggestions??? I am using C# Express
-- Rich
所有回覆
-
2009年7月8日 21:09
- This forum is for Microsoft Speech Server Questions. You'd be better server in a Desktop/Windows Speech forum. You should be able to find an appropriate forum by asking here - http://social.microsoft.com/Forums/en-US/whatforum/
- You should ensure that you have added a reference to the assembly that contains the namespace.
- 已提議為解答 Ahmed Stewart [MSFT] 2009年7月8日 21:09
-
2009年7月9日 19:26Sorry. The assembly I am trying to get at with C# is System.speech.recognition. The compiler doesn't know about System.speech. Do I need to download Microsoft Speech Server, and, if so, the only one I can find on Microsoft's web site is version 5.1. I understand that there is a later version ?5.3. Where do I go to get that? Thanks.
-- Rich -
2009年7月10日 21:05System.Speech.Recognition is a namespace not an assembly - http://msdn.microsoft.com/en-us/library/system.speech.recognition.aspx You need to reference the assembly that contains that namespace in your project i.e. System.Speech.dll
The 5.1 & 5.3 that you're referencing are for the Speech API which is NOT Microsoft Speech Server.
In General yes, if you want to use the functionality of an assembly you will need it on the machine that you're using to develop the code.