简体   繁体   English

将模型添加到启用了Silverlight WCF ria服务的应用程序

[英]Adding Models to the silverlight wcf ria services enabled application

I have started using the MVVm light2 framework for the wcf ria enabled silverlight 4.0 application. 我已经开始对启用了wcf ria的silverlight 4.0应用程序使用MVVm light2框架。

I was able to add a folder named "Models" to ASP .Net application that hosts the silverlight application, I added a class to this folder, and i am able to set the properties and all for this in my silverlight application, but once i started to add more such classes into my Models folders, they aren't getting accessible anywhere in my silverlight application. 我能够向承载Silverlight应用程序的ASP .Net应用程序添加一个名为“模型”的文件夹,向该文件夹添加了一个类,并且能够在我的Silverlight应用程序中设置属性以及所有这些属性,但是一旦我开始在我的Models文件夹中添加更多此类类,但在我的Silverlight应用程序中的任何地方都无法访问它们。

Also in my MainViewModel.cs the intellisense is not showing the newly added class/classes , i made sure the application is build before i accessed them in my silvelight application, also the namespaces are correct. 同样在我的MainViewModel.cs中,智能感知未显示新添加的类,我确保在我通过silvelight应用程序访问它们之前,该应用程序已构建,而且名称空间也正确。

Am I missing to set a property or something? 我是否想设置财产或其他东西?

Someone on my team faced a similar problem. 我团队中的某个人也遇到了类似的问题。 As I recall it had something to do with the physical location on the .cs files, which may imply that the namespace had changed. 我记得它与.cs文件上的物理位置有关,这可能意味着名称空间已更改。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM