Switch On The Code RSS Button - Click to Subscribe
Jun
6

Silverlight 2 and Twitter - A Simple Example

It might be a surprise to see me (The Fattest) writing about Silverlight, but I have had some fun playing around with it recently. So I decided I would write up a quick tutorial on how to build a Silverlight widget that shows the last five tweets (messages) from twitter. Now be forewarned I am not a C# expert, two other people at SOTC are, nor am I a Silverlight expert. I do however really enjoy playing around on twitter (The Fattest’s Twitter Account) and with RIAs so I think I am qualified enough. :)

 
Read More »

Posted in Silverlight, C#, All Tutorials | 1 Comment »

Apr
7

Silverlight DataGrid - The Basics

I finally downloaded and started using Silverlight 2.0. In a nutshell, it’s worlds better than Silverlight 1.0 and 1.1. Of all the new controls we now have access to, the one I was most interested in seeing was the DataGrid. WPF doesn’t even have a DataGrid (if you don’t count the ListView with a GridView applied), so I surprised when I learned Silverlight was shipping with one. This tutorial is going to introduce you to the DataGrid and demonstrate how to populate it with data from an RSS feed.
 
Read More »

Posted in Silverlight, All Tutorials | 10 Comments »

Feb
28

Silverlight 2.0 - The Controls Have Arrived

If you’ve haven’t heard about Silverlight 2.0 yet, you’re probably living in a dark corner of the world. Just in case you need a refresher, you can check some posts about it here, and here, and here, and here, and pretty much any other developer news site.

Silverlight is definitely in the same realm as Flex, but up until now I couldn’t see why a developer would ever choose Silverlight. As I worked more and more with WPF, I began to realize that if Microsoft were able to port the power of that framework to the web, it would own the RIA space. It looks as though Silverlight 2.0 has made a major leap in that direction. The pairing of .NET 3.5 and WPF has, in my mind, created the best environment for rich applications that currently or has ever existed. We here at Switch On The Code are eagerly awaiting the release of Beta 1 to see if it’s as good as it looks.
 
Read More »

Posted in Tech News, Silverlight | 4 Comments »

Feb
20

Creating an XP Style WPF Button with Silverlight

Way back in October I posted a tutorial on how to use custom controls in Silverlight. In that post I used an example button that looks like the Windows XP WPF button. Since then a couple of people have expressed interest in how to build that button. This tutorial is going to show exactly that.
 
Read More »

Posted in Silverlight, All Tutorials | 6 Comments »

Oct
12

Silverlight Tutorial - Using Isolated Storage

So, a little while back, we posted a little rant about how isolated storage in Silverlight is a great idea, but how its usefulness is extremely limited. And while that still is true, that doesn’t stop the concept from being cool. So today we are going to take a look at how to write a Silverlight app that uses isolated storage.
 
Read More »

Posted in Silverlight, All Tutorials | 1 Comment »

Oct
3

How to Use Custom User Controls in Silverlight

Since Microsoft hasn’t released an official library of controls for Silverlight, making and using your own is very important. This tutorial is going to show you how to import and add a custom control to your Silverlight application.
 
Read More »

Posted in Silverlight, All Tutorials | 4 Comments »

Oct
1

Silverlight Tutorial - Animating HTML Elements

Animation! And more animation! We sure do seem to love animation here at Switch On The Code - and really, I have no idea why. But as long as we keep coming up with cool concepts that deal with animation, we will continue to write about them. Today we are going to take a look at something a little bit weird - we are going to animate HTML elements using Silverlight. Thats right, you read that correctly - HTML elements, the stuff you would normally animate with some plain old javascript - perhaps even the Generic Animation javascript code. Why would you want to do this? I don’t have any good reasons at the moment. But it does show off some of the capabilities of silverlight, and that is a good enough reason to write about it.
 
Read More »

Posted in Silverlight, All Tutorials | 3 Comments »

Sep
25

Silverlight Tutorial - Interaction With The DOM

Today we are going to take a look at directly manipulating the DOM on a webpage using silverlight. We have other tutorials about silverlight interacting with the webpage it is placed on, but in those tutorials we always communicate through some javascript functions on the page. Here, we will not be writing a single line of javascript - everything will be done in the silverlight code-behind (which in this case will be C#).
 
Read More »

Posted in Silverlight, All Tutorials | 1 Comment »

Sep
24

Where is Silverlight’s Isolated Storage Image Support?

Recently, we decided to write a tutorial on how to use Silverlight’s isolated storage. In theory, isolated storage is a great feature that allows Silverlight to view offline content. In practice, however, you’re pretty limited on what it can be used for.
 
Read More »

Posted in Rants, Silverlight, All Tutorials | 6 Comments »

Sep
7

How To Embed Silverlight Into a Webpage

Since we’ve started posting Silverlight tutorials, I’ve had to figure out how to get Silverlight applications embedded into our blog. Needless to say, I found the process a lot harder than it should be. Visual Studio provides a test page as part of a default Silverlight project, but what if you want to take the Silverlight application and put it in a blog post like we do? This tutorial will go through all code changes, files needed, and new code required to easily embed your Silverlight apps into existing webpages.
 
Read More »

Posted in Silverlight, All Tutorials | 6 Comments »

Sep
4

Silverlight Tutorial - Color Animations

In this tutorial, I’m going to show you how to use Silverlight’s Storyboard and ColorAnimation XAML tags to create custom color animations. Color animations are commonly used on input controls like buttons to give visual feedback that the cursor is over the control or when the button has been pressed. This tutorial will show a couple of simple examples that can easily be extended to complex controls and animations.
 
Read More »

Posted in Silverlight, XAML, All Tutorials | 5 Comments »

Aug
20

Communicate Between Flex and Silverlight using Javascript

If Flex can communicate with Javascript and Silverlight can communicate with Javascript, it seems like there should be some sort of transitive rule that let’s Flex communicate with Silverlight. Well there is, and this tutorial is going to show you how to use Javascript to communicate directly between a Flex application and a Silverlight application.
 
Read More »

Posted in Silverlight, Flex, Javascript, All Tutorials | 7 Comments »

Aug
15

Silverlight and Javascript Interaction

Silverlight is a relatively new client side technology released by Microsoft, but already people are finding the need to communicate between their Silverlight applications and Javascript. This tutorial will go through all the code required to call Javascript functions from Silverlight and vice-versa.
 
Read More »

Posted in Silverlight, Javascript, All Tutorials | 1 Comment »

Jul
30

Getting Started With Silverlight

Since the release of Silverlight 1.1 alpha refresh and Visual Studio 2008 beta 2, I decided to start a series of tutorials for Microsoft’s Silverlight. If you haven’t heard of Silverlight, I strongly suggest checking it out. It’s a new web technology developed by Microsoft meant to compete with Flash and Flex.
 
Read More »

Posted in Silverlight, C#, All Tutorials | 4 Comments »