WPF MVVM Thread annoyance

In WinForms one of the annoyances is that any GUI operation requires invoking GUI thread to do it. I wrote a blog article on a quick hack to bypass it. I was really hoping this limitation was gone in WPF, but alas… Lately I’ve been refactoring my IRC client to use a MVVM-like architecture. In MVVM ViewModel should… Read More »

Refactoring IRC client with MVVM and “MDI”

A screenshot of the first working window after refactoring the IRC client. I had to create my own MDI window in WPF as it doesn’t support it. Extra fun when it doesn’t support inherited user controls, but that wasn’t too difficult to solve. Just made a class to inherit MDI window and then programmatically added a user control… Read More »

MVVM (and my IRC client)

This post is a bit of a personal rant on whether or not to use MVVM. I’m comparing MVVM with my current architecture and try to look at a few pros and cons. Clearly MVVM is not optimal, but there might be parts to borrow. At the moment I’m doing some heavy refactoring of the IRC client I’m… Read More »

C# / .Net WinForms GUI Thread Invoke solution

In .Net WinForms (and WPF for that matter) only the main GUI thread is allowed to make any change to GUI. If you attempt to do so from another thread then Visual Studio MDA will let you know that you made a mistake. This is actually an improvement from VS2003 where nobody said anything, so your application would… Read More »

BitLocker startup error 0x26000070

I’m using BitLocker for HD encryption on all partitions, USB disks and USB pens. For USB* it works fine by just asking for a password. But for HD encryption it is a bit more complicated. Basically BitLocker should encrypt your HD without you having to provide any password at every startup. It should also be secure from tampering… Read More »

ASP.Net Unhandled Exception Handling: Email exception with MiniDump

For most ASP.Net applications I make I add some code that emails me any unhandled exceptions. This way I immediately know when something has gone wrong with an application. The email contains a lot of useful information, including a MiniDump of the process. If you are not familiar with it, a MiniDump is a snapshot of the process… Read More »

Embedding YouTube in WPF WebBrowser control

Embedding YouTube into your C# WPF application can be done by wrapping embedded YouTube in a WebBrowser object (Internet Explorer). There are a couple of things you need to do to make it work. Tested on Windows 7 Ultimate 64-bit in .Net 3.5 (VS 2010). Sample code can be found at the bottom. Add Mark of the Web… Read More »

Help on IRC client

I’m working on an IRC client and looking for people to help… The client is currently functional, but missing a lot of GUI-stuff like channel bar, friends list and other neat functions. It’s written in C# with WPF GUI. All functionality is implemented through modules (.dll-files) and dynamically loaded after client has started. I’m looking for both beta… Read More »