Reputation: 93
I want to add non-silverlight assembly to a silverlight project, is there any way to do this? or what will be the other option to do ?
Upvotes: 1
Views: 157
Reputation: 64949
As Andrey writes, it's impossible to add a non-Silverlight assembly to a Silverlight project. If you really need to use it, you have no option but to run it server-side. You may already have a Web project that goes with the Silverlight project, and if so, that's where you should add a reference to this assembly.
The technology used to make remote calls from Silverlight to the web project is WCF RIA Services. The page I linked to contains plenty of documentation and videos to help you learn about WCF RIA Services.
There are, however, a few situations in which this approach won't work. Perhaps none of them apply to your circumstances, but since you don't provide any details about this assembly, I can't be sure.
There are a number of things that I can think of that should work reasonably well over WCF RIA Services:
Upvotes: 1
Reputation: 60055
It is impossible because Silverlight has different runtime from full .net framework. The common way to solve it is to create WCF service that will have access to that assembly and provide remote access for Silverlight application.
Upvotes: 1