ALLINSIGHT

Home of the AlmostImplementedException

April, 2013

WPF: How to use an image as brush

When you want to use an image as brush, you have to decide where to put it. Best and easiest way is to include it as resource to your project. Simply add to picture to your project (maybe in an subfolder called images) and change “build action” to resource, if its not already set. To […]

, ,

Creating a process monitor

In a previous post I wrote about debugging another application with mdbg. In this context I started to build an application that is able to log exceptions in other applications. But in some cases you can’t be sure that the monitored application is always running. So whats about e.g. small apps started by task scheduler? […]

How to check if a class is static

With the abstract class Type you can get alot of information about anything in C#. But although there are alot of Is… properties, there is no IsStatic. If you want to know if a class is static you have to use IsAbstract and IsSealed. When both are true then you have a static class. To […]

Debug another application

Today I will show up how we could build an application that is able to can debug another. Since a while I got a problem to control an obsolete program that is productive for a while in the company I work, because it is regulary crashing and we have to know when this happens to […]

, , , ,

How to find large tables in Sql Server

Sometimes it is necessary to find out which tables are consuming the most space in your database. especially when you run your database for a couple of years. In our case we’ve got an ERP database which holds orders, position, customers, machine controls, print data, … So we need to find table that are predestined […]

, , , , ,

How to convert string to enum

It is good practice to use enums to choose which part of the code should be executed, but sometimes you’ll get a string and have to convert it to an enum. Here is, how you can do it. First, declare a custom enum or use a given one. And then use the Enum.Parse command. This […]

, , ,