Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/silverlight/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/entity-framework/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/webpack/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Silverlight 未在客户端中加载自引用表实体_Silverlight_Entity Framework_Wcf Ria Services - Fatal编程技术网

Silverlight 未在客户端中加载自引用表实体

Silverlight 未在客户端中加载自引用表实体,silverlight,entity-framework,wcf-ria-services,Silverlight,Entity Framework,Wcf Ria Services,我有一个带有外键的表Test。在元数据类中,我有 [Include] Test Test2 { get; set; } 在服务类中: return this.ObjectContext.Test.Include("Test2") 我检查了从数据库正确加载的数据。但在客户端,我看到没有加载任何父级 我使用DomainDataSource加载数据(Silverlight 4.0) 有人经历过这种奇怪的行为吗?好吧,我错了。答案是一如既往地使用[Include]属性,但要确保所有参与属性在元数据

我有一个带有外键的表
Test
。在元数据类中,我有

[Include]
Test Test2 { get; set; }
在服务类中:

 return this.ObjectContext.Test.Include("Test2")
我检查了从数据库正确加载的数据。但在客户端,我看到没有加载任何父级

我使用
DomainDataSource
加载数据(Silverlight 4.0)


有人经历过这种奇怪的行为吗?

好吧,我错了。答案是一如既往地使用[Include]属性,但要确保所有参与属性在元数据类中都是公共的