Tips

Doing less with LINQ

While reading a recent article in MSDN magazine, I came across some code that gives me a great opportunity to show how to get more done with less effort by using LINQ.

Avoiding Stack Overflow with Params

Here's a pattern that I've seen occur a number of times - a pair of method overloads, one accepting IEnumerable<T> and the other accepting params T[].

WCF and IList<T>

Here's an interesting problem I encountered recently with a WCF based web service and the humble IList<T> interface.

I'm working on a classic 3-teir system: Client/Application/Database. The Client and Application are using Windows Communication Foundation (WCF) to interact. For convenience, we have an assembly of Data Transfer Objects (or DTOs) which is shared across both the client and the server.

While working on a recent system enhancement, I encountered an odd error - a NotSupportedException with the message "Collection was of a fixed size".

Using TypeConverters with WPF

I'm working on a little project at the moment which is dynamically building a WPF user interface based on a configuration file loaded when the application starts. This involves code to manually create all of the bits and pieces that are normally specified directly in a Xaml file.

One useful shortcut I've found is to leverage .NETs built in TypeConverter framework - the same technique used by the Xaml loader itself.

Using Windows SignOn with PowerBuilder and SQL Server

Following The Good Samaritan Principle, here's a tip for people using PowerBuilder against a SQL Server back end with single-sign-on.

Syndicate content