Posts

Showing posts with the label Silverlight

Localizing your custom solution and Silverlight

While localizing my custom website hosting a Silverlight 3 control, I added multiple resource files (.resx) to my xap and when I hit the page I got this error: System.Windows.Markup.XamlParseException occurred Message="AG_E_PARSER_UNKNOWN_TYPE On hitting this link http://www.telerik.com/community/forums/silverlight/navigation/navigation-samples-failing-with-silverlight-3-because-of-urimapping.aspx I realized the goof up. One of the resx files had the constructor still declared as ‘internal’, and you get this error when the application is getting initialized and trying to access and internal resource. So I made the changes to set it to public, and it worked like a charm!!

Initializing distinct XAMLs included in a single XAP

So I had a situation where I had to load multiple charts on my custom page default.aspx within Microsoft Dynamics CRM. These charts rendered different reporting data after fetching it using the MS CRM webservices. I used silverlight visifire charts for each of my reports. Instead of creating a different silverlight application for each of my reports, I instead created different XAMLs for each of them and compiled a single XAP. Well, this is a well tried and tested approach used in any silverlight application or any aspx application using Silverlight controls which involves multiple XAMLs compiled in a single XAP. These are the steps I used: 1. Created a Silverlight application that contained multiple XAMLs each one including a different report (i.e. a different visifire chart) and compiled it as one "SLDashboardPOC.xap". 2. For each of the reports to be rendered, I embedded the compiled Silverlight XAP control multiple times in my default.aspx as follows: <asp:ScriptManage...