Project Summary
Using analytics software for your website is normally a straight forward task, you add a few lines of code and actions are captured through the java script functions that are been created by the analytic software provider. This however is different in Silverlight applications. In Silverlight, Java Script on your page cannot talk to you your code in Silverlight by itself, i.e. your Java Script code would not know if you click on a link in your Silverlight application. Therefore, you need to specifically tell your Java Script code actions like clicking link has happened by calling it from your Silverlight Application.
This project is the second part of Silverlight Tracking and explains how to track information about users and their platform, i.e. if the user has Silverlight installed and etc. To view the first part of this project visit:
http://silverlighttracking.codeplex.com.
Tutorial
Complete step by step tutorial can be found on Silverlight Tips here:
http://www.silverlighttips.com/?tag=/event+tracking
Q&A/Support
Visit Q&A for this specific project at Silverlight Forums here:
http://silverlightforums.com/showthread.php?p=3976#post3976.
Releases
Download the latest release for this project from here:
http://trackingsilverlight.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=40270.
Download the first release for this project from here:
http://silverlighttracking.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=39550.
Development Summary
1. add Silverlight.supportedUserAgent.js to your project2. add tracking code to Silverlight.supportedUserAgent.jsSample code:
if (version == '2.0') {
trackEvent("NoneSilverlight", "Unsupported silverlight", "Silverlight Version: 2.0");
return (supUA && (slua.OS != 'MacPPC'));
}
else if (version == '1.0') {
trackEvent("NoneSilverlight", "Unsupported silverlight", "Silverlight Version: 1.0");
return (supUA && (ua.indexOf('Windows NT 5.0') < 0));
}
3. If your Silverlight application was loaded4. if user interacts with the none-Silverlight version of your site/application5. Call CheckSupported()function