|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<!-- saved from url=(0014)about:internet -->
<head>
<title>ImageRotator</title>
<style type="text/css">
#silverlightControlHost {
height: 100%;
}
#wrapper {
text-align: left;
margin: 0px auto;
padding: 0px;
border:0;
width: 1000px;
background: url("/path/to/your/background_cols.gif") repeat;
border: solid 1px #868686;
}
#header
{
padding: 5px;
margin: 0 0 15px 0;
font-size: 32px;
font-weight: bold;
background: #414141;
}
#silverlightControlHost
{
padding: 5px;
float: left;
width: 400px;
}
#formControlsDiv {
margin-left: 10px;
float: left;
width: 480px;
padding: 5px;
height: 1% /* Holly hack for Peekaboo Bug */
}
#footer
{
padding: 5px;
clear: both;
background: #414141;
}
a {
font: italic 100%/1.0 Arial;
text-decoration: none;
}
a:link {
color: #d0eb55;
text-decoration: none;
}
a:visited {
color: #d0eb55;
text-decoration: none;
}
a:hover {
color: #d0eb55;
text-decoration: underline;
}
a:active {
color: #d0eb55;
text-decoration: none;
}
</style>
<script type="text/javascript" src="Silverlight.js"></script>
<script type="text/javascript">
function onSilverlightError(sender, args) {
var appSource = "";
if (sender != null && sender != 0) {
appSource = sender.getHost().Source;
}
var errorType = args.ErrorType;
var iErrorCode = args.ErrorCode;
var errMsg = "Unhandled Error in Silverlight 2 Application " + appSource + "\n" ;
errMsg += "Code: "+ iErrorCode + " \n";
errMsg += "Category: " + errorType + " \n";
errMsg += "Message: " + args.ErrorMessage + " \n";
if (errorType == "ParserError")
{
errMsg += "File: " + args.xamlFile + " \n";
errMsg += "Line: " + args.lineNumber + " \n";
errMsg += "Position: " + args.charPosition + " \n";
}
else if (errorType == "RuntimeError")
{
if (args.lineNumber != 0)
{
errMsg += "Line: " + args.lineNumber + " \n";
errMsg += "Position: " + args.charPosition + " \n";
}
errMsg += "MethodName: " + args.methodName + " \n";
}
throw new Error(errMsg);
}
</script>
</head>
<body style="background-color: #3d3d3d; color: #d0eb55; font-family: Arial;">
<div id="wrapper">
<div id="header">
Configurable Silverlight Image Rotator
</div>
<div id="container">
<div id="silverlightControlHost">
<object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="100%" height="100%">
<param name="source" value="ClientBin/ImageRotator_CSharp.xap"/>
<param name="onerror" value="onSilverlightError" />
<param name="background" value="white" />
<param name="minRuntimeVersion" value="2.0.31005.0" />
<param name="autoUpgrade" value="true" />
<!-- Begin: initParams for ImageRotator -->
<param name="initParams"
value="autoPlay=true,
autoPlayInterval=7,
numberedNavigation=true,
arrowNavigation=true,
stopStartAutoPlay=true,
animation=true,
border=true,
borderThickness=2,
imageRotatorDiv=silverlightControlHost,
browserWindowOptions=resizable=1|scrollbars=1|menubar=1|status=1|toolbar=1|titlebar=1|width=1000|height=725|left=5|top=5,
argb=255|0|0|0" />
<!-- End: initParams for ImageRotator -->
<a href="http://go.microsoft.com/fwlink/?LinkID=124807" style="text-decoration: none;">
<img src="http://go.microsoft.com/fwlink/?LinkId=108181" alt="Get Microsoft Silverlight" style="border-style: none"/>
</a>
</object>
<iframe style='visibility:hidden;height:0;width:0;border:0px'></iframe>
</div>
<div id="formControlsDiv"></div>
<div id="footer">
<a href="http://www.anothercodesite.com/Blog/2008/12/default.aspx">AnotherCodeSite.com</a>
</div>
</div>
</div>
</body>
</html>
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
I have been Software developer for the past 10 years. Mostly worked in web world in asp.net and c#. Recently began job using wpf and vb.net.
Also enjoy reading books on politics and American history, listening to music, and COD on XBox 360.
Visit my blog at:
www.anothercodesite.com/blog
All posts have source code for both C# and VB.