August 2008 - Posts

CollectionView.DeferRefresh() : My new best friend
28 August 08 02:23 PM | MattManela | 2 Comments   
Well, maybe not best friend but its a nice function.  When working with bound collections in WPF you often end up dealing with a CollectionView .  This is the MSDN documentation description of a CollectionView : You can think of a collection Read More...
Filed under: , ,
I started playing with F#...
22 August 08 09:23 AM | MattManela | 0 Comments   
I decided to do some Project Euler problems using F#.  So here is my first one, Problem # 31.  Nothing in this solution really shows off anything special about F# but you have to start somewhere ;)   1: #light 2:   3: let rec combos Read More...
Generic Insert and Update for LINQ To SQL
12 August 08 02:46 PM | MattManela | 1 Comments   
Quick code snippet time! The following are generic methods for inserting and updating a detached entity into a database using LINQ to SQL. 1: /// <summary> 2: /// Updates the database with item. 3: /// </summary> 4: /// <typeparam name="T">Type Read More...
Filed under: ,
Worst Case Scenario for QuickSort
04 August 08 09:54 AM | MattManela | 2 Comments   
Take a look at the following code: 1: var sw = new Stopwatch(); 2: sw.Start(); 3: Enumerable.Range(0, 3).SelectMany((i) => Enumerable.Range(0, 50000)).OrderBy(i => i).ToList(); 4: Console.WriteLine(sw.ElapsedMilliseconds); 5:   6: sw.Reset(); Read More...
The two most important WPF Tools
01 August 08 08:49 AM | MattManela | 0 Comments   
I have been working a lot with WPF and I found the following two FREE tools to be extremely helpful. The first is: XamlPadX - ( http://blogs.msdn.com/llobo/archive/2007/12/19/xamlpadx-v3-0.aspx ) This is an enhanced version of XamlPad which comes with Read More...
Filed under: , , ,
Page view tracker