Quantcast
Channel: Silverlight 5 forum
Viewing all articles
Browse latest Browse all 1083

Restructuring projects from Business application template

$
0
0

When using business application template, two projects are generated. I would like to restructure this setup, and I have added one Server.Data project that will contain edmx and services, and another Client.Data SL class libary that will be a link to Server.Data.

My question is this: When I move all required files from ASP.NET project to Server.Data project, adapt namespaces, I am able to compile both ASP.NET and Server.Data projects. After that I am setting a link to RIA in Slient.Data and adding to lnks to resource files from Server.Data. If I try to compile at this point, I will get not so helpfull exception

The code generator 'Microsoft.ServiceModel.DomainServices.Tools.CSharpCodeDomClientCodeGenerator' encountered a fatal exception and could not generate code for project '....csproj':
Exception has been thrown by the target of an invocation.

I have tried removing some services from Server.Data and I found out where the problem lies: if I commend out Display attribe on RegistrationData properties in Server.Data, I am able to compile. Howeever, I have notices so far that WebContext class is not being generated

There are also classess from Model folder in silverlight application project (User and RegistrationData, which I didnt add to Client.Data project, since I was not able to compile at all with them. Basically, compiler is complaining about all methods that they call, seems like it is not treating them as partial classes at all (like there are no 'base' classes).

What am I doing wrong, why is this so difficult, and what can I do to make it work? :)



Viewing all articles
Browse latest Browse all 1083

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>