Blog

posts from 2005

New VS2005 Macros

0 Comments
By Fons Sonnemans, 18-11-2005

Three years ago I have written some useful Visual Studio 2003 macros: SortCode and CreateProperty. With the introduction of VS2005 it was time to upgrade them.

The new SortCode macro also supports VB.NET 2005. Totally new is the EncapsulateAllNonPrivateFields macro. It creates properties get/set for all non private (public, protected, internal) fields. By using the CodeDom I managed to supports VB.NET and C#.

Example

After running the marco the 3 fields are private and there are 3 extra properties.

Download Zipfile

Qliner hotkeys

0 Comments
By Fons Sonnemans, 11-11-2005

A friend of my send me a link to a great freeware software application. I love it!

Qliner hotkeys is a free and open source keyboard productivity environment. It is the first product of it's kind that is usable by computer geeks and non geeks alike.

Key features:

  • Smart Application Launching
  • Smart Application Instance Switching
  • Drag and Drop Configuration using an Onscreen Keyboard
  • Support for 100+ International Keyboards (making it a handy tool for international keyboard users).
  • Support for Dvorak keyboards
  • Volume Control Add-in
  • Clock Add-in
  • Optionally maps Caps Lock key to Window key (handy if your keyboard does not have a Windows key or if you just hate the default bahavior of Caps Lock)

Hotkeys builds on the concept of Windows shortcut keys but takes this concept to a whole new level. Do you think key combinations are hard to remember? Just hold the Windows key for three seconds and up pops a Onscreen Keyboard with icons on the keys that are configured. This you can you use , not only to remind you of hotkey combinations, but also for Drag and Drop Configuration.

Tags: Windows

Websites using my CMS are online

0 Comments
By Fons Sonnemans, 20-10-2005

I have written a small content management system using ASP.NET. Sjef de Corte has implemented 3 websites with it. Well done Sjef!

Tags: Web, ASP.NET

More Avalon/XAML Minesweeper samples

0 Comments
By Fons Sonnemans, 1-10-2005

I have found two more Avalon Minesweeper implementations.

BTW I plan to post the sourcecode of my implementation soon. I have to clean it up first.

What is an architect?

0 Comments
By Fons Sonnemans, 29-9-2005

I just saw the great Sparkle video on Channel9. On of the most funny part was the question 'What is an Architect?'. The anwer from John Gossman was 'It is a fancy title for a programmer' or in other words 'You are old'. I hope you enjoy the movie, I did. I can't wait to play with it.

Tags: Work

Avalon and ClickOnce demo

0 Comments
By Fons Sonnemans, 23-9-2005

I have build my first Windows Presentation Foundation (WPF) application. It is a remake of my WinForms Minesweeper game. Go to the ClickOnce publisher page and install Avalon Minesweeper.

Make sure you have the Microsoft Pre-Release Software WinFX Runtime Components - September Community Technology Preview (CTP) installed on your computer.

To run this sample you must add 'http://www.mydotnetplayground.nl/WpfMinesweeper' to your Trusted Sites in Internet Explorer.

UPDATE 1-1-2006: Moved to my own provider and updated to the December CTP.

Tags: WPF, CSharp

SDE Slides

0 Comments
By Fons Sonnemans, 20-9-2005

The slides from my presentation 'NDoc Integratie in Visual Studio 2003 & 2005' can now be downloaded.

C# 3.0 looks like Smalltak

0 Comments
By Fons Sonnemans, 14-9-2005

Many years ago I programmed in Smalltalk (Enfin which later became ObjectStudio). I have always liked it although it was not very programmer friendly (no IntelliSense). I have just wachted this C# 3.0 Language Enhancements in action video. The shown Extension Methods feature realy looks like the Secondary Class files of Smalltalk. Nice to see them back, they where very handy.

In the following example I have added the 'IsPrime()' method to the 'Int32' type. The 'this' keyword in front of the 'number' parameter of the IsPrime() method did the real trick. This makes it an Extension Method.

class Program {
    static void Main(string[] args) {
        Console.WriteLine(5.IsPrime()); // true
        Console.WriteLine(9.IsPrime()); // false
        Console.WriteLine(23.IsPrime()); // true
    }
}

static class Extensions {

    public static bool IsPrime(this int number) {
        if (number == 1 || number == 2 || number == 3) {
            return true;
        }
        if ((number % 2) == 0) {
            return false;
        }
        int sqrt = (int)Math.Sqrt(number);
        for (int t = 3; t <= sqrt; t = t + 2) {
            if (number % t == 0) {
                return false;
            }
        }
        return true;
    }
}
Tags: CSharp

PDC05 Keynote

0 Comments
By Fons Sonnemans, 13-9-2005

I have just watched the live PDC05 Keynote Webcast. I'm very impressed. Great demo's showing LINQ, Indigo, Atlas and Avalon. The problem for Microsoft will be to get us 'the developers' to use these new technologies as soon as possible. I'm afraid it is all to much for a 'normal' developer too cope with.

SDN Software Developer Event

0 Comments
By Fons Sonnemans, 30-8-2005

I will be speaking at the SDN Software Developer Event on the September 16 2005, De Reehorst - Ede . I will talk about the integration of NDoc with Visual Basic 2003 and 2005. Hope to see you there.

12>

All postings/content on this blog are provided "AS IS" with no warranties, and confer no rights. All entries in this blog are my opinion and don't necessarily reflect the opinion of my employer or sponsors. The content on this site is licensed under a Creative Commons Attribution By license.