Print Page | Close Window

Creating the Silverlight Link in an Existing Project

Printed From: IdeaBlade
Category: DevForce
Forum Name: DevForce 2010
Forum Discription: For .NET 4.0
URL: http://www.ideablade.com/forum/forum_posts.asp?TID=2101
Printed Date: 10-Jun-2026 at 5:28pm


Topic: Creating the Silverlight Link in an Existing Project
Posted By: benmcneill
Subject: Creating the Silverlight Link in an Existing Project
Date Posted: 26-Aug-2010 at 10:25pm
Hi Guys
 
I have a large existing Silverlight Project which was originally created using a Silverlight Business Application Template.
 
I'm trying to swith over to using DevForce, and have created my EDMX and the automated DevForce 'Project.IB.Designer.CS' in the Web Project, but the Silverlight 'Linked File' is not appearing in the Silverlight Project.
 
I've created a 'Shared Code' folder under the Silverlight Project, have added all IdeaBlade assemblies to both projects, have modifed the Web application web.config project to represent the settings show in the Learning folder (Learning Resources\110_Deployment\Snippets\IIS Files\web.config), and tried adding EntityServer.svc and EntityService.svc to the Web Application project as was suggested in the 'DevForce Silverlight Apps.pdf' file also.
 
I've compared the files and settings in this project and a 'new' DevForce Silverlight Project but can't see what I'm missing.
 
Would greatly appreciate some help.
 
Thanks,
Ben
 
 



Replies:
Posted By: ting
Date Posted: 27-Aug-2010 at 4:03pm
Are you using DevForce 6.0.4?  I just tried adding a new EDMX to a freshly created application using the Silverlight Business Application Template and did get the linked file in the Silverlight project.  However, you can manually link it by right clicking the Silverlight project and selecting Add -> Existing Item and then choosing "Add as Link" in the combo box on the bottom right.
 
If you don't start from our DevForce Silverlight Application template, I strongly suggest that you create a stub application from it and copy over the settings.  In particular, make sure you pick up the Global.asax and get the correct settings from the web.config.  You can delete the .svc files as the line the in Global.asax now takes care of that.
 


Posted By: kimj
Date Posted: 27-Aug-2010 at 6:11pm
The linkage is done automatically by DevForce only when the SL assembly name "corresponds" to the assembly name of the .NET project holding the EDMX.  To correspond, the SL assembly name must be the same as the .NET project; or be the same as the .NET project stripped of any ".Web" suffix; or start with the .NET assembly name followed by a "." something.  For example, if your EDMX is in a project with an assembly name of "DomainModel", then automatic linkage would occur if the SL project was named "DomainModel" or "DomainModel.SL" or similar.
 
As Ting noted, you can always manually add the file as a link, since there's nothing special about the link that DevForce creates.


Posted By: benmcneill
Date Posted: 27-Aug-2010 at 8:08pm
Thanks Guys. The Assembly name seemed correct, but still would not generate, so I did so manually.



Print Page | Close Window