.NET 3.5

C# Snippet Tutorial - Determining if Aero is Enabled


Posted in:

Recently I was working on a project and the UI required minor tweaks depending on whether or not Aero was enabled. Fortunately, I came across an MSDN forum topic with the solution, so I thought I'd share.

Read More Icon Read More

WCF Snippet Tutorial - Overloading Methods


Posted in:

This snippet will show you how to add overloaded functions to your WCF service contracts.

Read More Icon Read More

Creating a REST Client using WCF


Posted in:

A couple of weeks ago we received an email about consuming a REST service in WCF. Well, this tutorial should answer that email. Today we're going to build a simple client for Twitter's REST API using WCF.

Since it doesn't look like WCF natively support OAuth authentication, the client we're going to write will do one simple thing - request the latest status updates for a specific user. I'm going to write a command line application that asks for a username and then prints a bunch of status updates along with information about the user. Below is some example output.

Read More Icon Read More

Silverlight DataGrid Tutorial - Using a DataGridTemplateColumn


Posted in:

Whenever you pit designers against developers, it always seems to be the developer that loses. It's very rare that controls like the Silverlight DataGrid are left alone - designers want little tweaks and polish to increase the user experience. This tutorial is going to illustrate how to use one of the most flexible solutions to theming a DataGrid - the DataGridTemplateColumn.

Read More Icon Read More

WPF Tutorial - Custom Control Templates


Posted in:

Almost every control in WPF uses a control template to define how it displays itself and its contents. In fact, you can override the control template on every built-in control to make it appear and act exactly like you want. Rather than overriding an existing template, however, this tutorial is going to demonstrate how to build a custom content control and use a control template to define how it looks.

Read More Icon Read More

WPF - Print Queues And Capabilities


Posted in:

We have taken a look at printing in WPF twice before here at SOTC - first with a simple tutorial on just getting something printed, and then a more complex one on pagination. Today we are not going to focus much on the printing side of things, but more on the printer side. For example, how do you get a list of the printers available on the system? Or their capabilities? If you need the answers to those questions, then this is the tutorial for you.

Read More Icon Read More

WPF Tutorial - Implementing IScrollInfo


Posted in:

The ScrollViewer in WPF is pretty handy (and quite flexible) - especially when compared to what you had to work with in WinForms (ScrollableControl). 98% of the time, I can make the ScrollViewer do what I need it to for the given situation. Those other 2 percent, though, can get kind of hairy. Fortunately, WPF provides the IScrollInfo interface - which is what we will be talking about today.

Read More Icon Read More

Creating a Simple Windows Service in C#


Posted in:

We all know what a Windows Service is - a long running executable that's designed to work without user interaction. They can be configured to start when the system boots and they can be run without any users logged into the system. This tutorial is going to provide step-by-step instructions on how to build a Windows Service using C# and .NET.

Read More Icon Read More

Book Review - WCF 3.5 Unleashed


Posted in:

I received this book from the publisher a while ago and I've finally made it through and found some time to write up a review. Generally I really like doing book reviews, but I also like to thoroughly read the book before I dive into writing about it - which leads to a long delay between reviews. That aside, here's a review of "Windows Communication Foundation 3.5 Unleashed" by Craig McMurtry, Marc Mercuri, Nigel Watling, and Matt Winkler.

Read More Icon Read More

WPF Printing Part 2 - Pagination


Posted in:

About two weeks ago, we had a tutorial here at SOTC on the basics of printing in WPF. It covered the standard stuff, like popping the print dialog, and what you needed to do to print visuals (both created in XAML and on the fly). But really, that's barely scratching the surface - any decent printing system in pretty much any application needs to be able to do a lot more than that. So today, we are going to take one more baby step forward into the world of printing - we are going to take a look at pagination.

Read More Icon Read More

Sponsors