创建并加载语法错误(创建SpeechGrammar) [英] Create and load a grammar error (Creating SpeechGrammar)

查看:75
本文介绍了创建并加载语法错误(创建SpeechGrammar)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我跟随了来自http://wwwmsdn.microsoft.com/en-us/library/jj131035.aspx的SpeechBasics

I followed SpeechBasics from http://msdn.microsoft.com/en-us/library/jj131035.aspx

我创建了SpeechGrammar.xml,它是在我的项目中。我也在我的Resources.Designer.cs中创建了SpeechGrammar :: string。

I've created SpeechGrammar.xml and it's in my project. I've made SpeechGrammar::string in my Resources.Designer.cs too.

但是下面的代码给出了错误"当前上下文中不存在名称'属性'。 "我缺少什么?

But this code below gives an error "The name 'Properties' does not exist in the current context." What am I missing?

using (var memoryStream = new MemoryStream(Encoding.ASCII.GetBytes(Properties.Resources.SpeechGrammar)))

推荐答案

它正在寻找属性命名空间,但无法找到它。检查您的推荐。 
It's looking for the Properties namespace and cannot find it. Check your references. 


这篇关于创建并加载语法错误(创建SpeechGrammar)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆