Page view counter

Silverlight Tips of the Day - Blog by Mike Snow

Game Programming with Silverlight

Browse by Tags

All Tags » visual web developer (RSS)
Silverlight Tip of the Day #105 – How to Enable GPU Acceleration
With the release of Silverlight 3 Beta 1 GPU (Graphics Processing Unit) acceleration (or hardware acceleration) is now available. The GPU is a processor attached to your graphics card that is generally used for calculating floating point operations. In...
Silverlight Tip of the Day #103 – Use Integers for Layout Calculations
When calculating the positions of objects such as Images make certain to use integer values not floating point values. For example, take a look at this code that centers a map around a given position: private void CenterMap( double windowWidth, double...
Silverlight Tip of the Day #101 – Silverlight 3 Beta 1 Feature Summary
Unless you have had your head under a rock you probably have heard Silverlight 3 Beta 1 has been released! If you haven’t already, please install it from http://silverlight.net/getstarted/silverlight3/default.aspx This release comes packed with some of...
Silverlight Tip of the Day #99 – Silverlight 3 Game Programming Book
I would like to announce that I am currently working on a book titled “ Silverlight Game Programming ” due to be released around June this year! You can find it on Amazon by clicking here . It’s taking most of my blogging time up so I apologize for the...
Silverlight Tip of the Day #97 – How to get an Image’s Source File Name
Once you have an image loaded how do you go back and get the original file name for the source file? This can be accomplished through the Uri property of the images Source . However, you must first typecast the images Source to be a BitmapImage . The...
Silverlight Tip of the Day #95 – Working with Strokes in Shapes
When it comes to drawing shapes such as rectangles you are probably fully aware you can draw shapes specifying the color and thickness of the lines. This is done via the properties StrokeThickness and Stroke . For example, take a look at the rectangle...
Silverlight Tip of the Day #94 – Reading XML through LINQ with Silverlight
In Tip of the Day #93 I showed you how to read XML via XmlReader . However, a better and simpler approach (IMHO) would be to use LINQ. Let’s start with the same XML file we used in Tip #93. <?xml version= "1.0" encoding= "utf-8"...
Silverlight Tip of the Day #93 – Reading XML with Silverlight
XML (Extensible Markup Language) is a great format for saving structured data in. In this Tip I will be showing you how to read and process XML files from Silverlight using the XmlReader object. Let’s say, for example, you want to store a tree structure...
Silverlight Tip of the Day #92 – How to Load Images from a Stream
In Tip of the Day #86 I showed you how to load external images not included in the project such as images on the web. In this Tip I will be showing you had to load images from the client’s machine through a file stream. Due to obvious security reasons...
Silverlight Tip of the Day #91 – How to Apply Themes from the Silverlight Toolkit
In addition to controls, the Silverlight Toolkit comes with a great set of themes that can easily be applied to your controls. These themes currently include: Bureau Black Bureau Blue Expression Dark Expression Light Rainier Purple Rainier Orange Shiny...
Silverlight Tip of the Day #90 – How to Edit your CSPROJ File from VS
The CSPROJ file, saved in XML format, stores all the references for your project including your compilation options. There is also a SLN file which stores information about projects that make up your solution. If you are using Visual Studio and have the...
Silverlight Tip of the Day #89 – How to use String Resources
In this Tip I will be showing you how to place hard coded strings into a resource area. This is a common best practice for software development that makes it much easier to manage the strings in your application. To start, open up your App.xaml file and...
Silverlight Tip of the Day #88 – How to handle image AG_E_NETWORK_ERROR errors
If you have ever worked with images while developing and running Silverlight app you have more than likely come across the AG_E_NETWORK_ERROR  exception. This exception is thrown if an image was not able to load for whatever reason (I.e. it couldn...
Silverlight Tip of the Day #87 – How to Change the Startup Class
When a Silverlight application is launched the entry point is a class that inherits from System.Windows.Application. By default, when you create a new Silverlight application project, this would be your App class which gets defined in App.xaml.cs. You...
Silverlight Tip of the Day #85 – How to Save $$ on the Silverlight MIX Conference
A $400 discount is available for a limited time for customers who register for MIX by Feb 13th. To receive the discount you should use the MIX09offer RSVP code at the beginning of the registration site. To register go here: https://register.visitmix.com...
Next