Silverlight type exists as in DataContractSurrogates

I am using silverlight 4 with ria serivces ..
I got an error message:

The type "eLab.Web.SessionsHWFile" exists in both "eLab.Web.dll" and "DataContractSurrogates_c96b3601-cd13-4049-93bb-e7b3f59a4fd9"

where eLab.Web is the aspx web project that hosts the silverlight project, and SessionHWFile is the edmx element, this is not a real table in the database, but VIEW. I dragged the grid from the data source and applied it to the XAML user control and used the query to get the data from the stored procedure into the database, but I get the above error when I debug the code and expand the presentation of the results: alt text http: //www10.0zz0 .com / 2010/07/26/22 / 244157379.jpg

I did this by adding a view and getting the results from SP to the database like a million times, and nothing happened before that time.

+4
source share
1 answer

** I seem to know that the problem is that ... I found that you cannot name two "riaControls: DomainDataSource" with the same name, even if they are different xaml pages.

Honestly, I don’t know why yet, but this is how I fixed the problem.

Just change the Name property "riaControls: DomainDataSource" ... **

0
source

All Articles