Tuesday 10 April 2012

how to connect silverlight application to dynamic crm 2011 custom ribbon button

for this:
1. in silverlight application.
select the .aspx page
ex: simplehelloTestPage.aspx (it is located in simplehello.web)
2. see the <param name="source" value="ClientBin/simplehello.xap"/> line.
In HTML page
3.give the below line
<script src="../ClientGlobalContext.js.aspx" type="text/javascript"></script>
instead of below line.
    <!--<script type="text/javascript" src="Silverlight.js"></script>-->
4. give the object id : <object id="SLFromJS" data="data:application/x-silverlight-2

5. now in the crm 2011 screens:
create one solution for this add webresource like:
give the name like:
new_test/ClientBin/simplehello.xap

6.create another web resource with the name:
new_test/hellohtml.html  

now  go for customization.xml for perticular entity where u created custom button.
then in the actions of particular button  give  like.
<Actions>
 <Url Address="$webresource:new_test/hellohtml.html"PassParams="true"></Url>
</Actions>
 
 then click on button you will get the silverlight application.

http://msdn.microsoft.com/en-us/library/gg309558.aspx

No comments:

Post a Comment