How to add a Silverlight page into a SharePoint 2010 Application Page? I know how to deploy the .xap file by adding the SL project as a module in a SharePoint 2010 project and create the .wsp file using VS2010. But you still have to use a SP2010 content page to add the Silverlight webpart to consume it. How to add it to the Application Page.
1 Answer
Check this guide on how to add an application page to a Visual Studio 2010 / SharePoint project.
This is only available for farm solution projects, not for Sandboxed projects so make sure you are not using Sandboxed. For full list of differences between these two click here.
-
1If you need to do it in the Sandbox. Then use this approach to create a page wictorwilen.se/Post/… and just use the Silverlight Web Part and the XAP file in a doc lib (or similar) Commented Apr 17, 2011 at 8:50
-
-
The question is NOT how to create a application page. Rather how to add your silverlight code in an application page and being able to debug in a farm based VS project (not a sandbox). I am aware of the approach linked by Toni as well and that's not what I'm looking for. Commented Apr 22, 2011 at 20:06
-
@wictor - do you think we can just use the object tag generated by the silverlight webpart? But I still won't be able to debug it along with the rest of the SharePoint projects. Commented Apr 22, 2011 at 20:22
-
Ok, if you want to debug Silverlight code in your SharePoint solution then you need to go into the project properties and select Enable Silverlight Debugging on the SharePoint settings tab. Commented Apr 22, 2011 at 20:45