Notice: This repository moved to github.com/sizingservers/sizingservers.log and github.com/sizingservers/sizingservers.util. It will not be kept up to date here anymore. Thanks to everyone who used this project!


This CodePlex project contains a set of utility classes that I use in various work related and pet projects. The reason I made this CodePlex page is because I wanted to give something back to the community.

All code is written in c# and the vs2013 projects compile to 64-bit binaries using .net 4.5. The code is well documented.

Sources, binaries and examples are available under MIT license.

If you find bugs or have valid suggestions(I love to learn), do not hesitate to contact me.

Currently following utils are available:
  • BackgroundWorkQueue: You can enqueue delegates here to be processed by a background thread. Handy for work that needs to be done in order without blocking the main thread.
  • CompilerUnit: Facilitating compiling string input. Compiles C# .net 4(.#).
  • Countdown: A countdown build using a timer.
  • DataGridViewImageCellBlank: A winforms class. Draws a blank image for replacing the ugly, unneeded 'no image' image if no image is set. Put an instance of this in the CellTemplate of a DataGridViewImageColumn. No example available yet.
  • FastObjectCreator: To create an object using intermediate language instead of Activator (if possible). Only an empty constructor can be used. Used to be faster than Activator (no checks), but maybe not anymore. I have to do some testing.
  • FindAndReplace: Find and replace made easy (no complicated regex stuffs). Uses old-school Google tokens.
  • FunctionOutputCache: Inspired by APC. Output that stays always the same, but takes long to calculate, gets cached. For example: A datatable. No example available yet.
  • InputDialog: A blast from the past, the VB6 input dialog in 'modern' winforms.
  • KeyValuePairControl: Winforms control to visualize a key value pair. No example available yet.
  • KeyValueStore: A super-simple in-memory kvp store. Used as building block for TimeSeriesStore. No example available yet.
  • LargeList: A winforms control that can list a large amount of child controls. It is in fact an advanced pager.
  • Log: This is my take on an application logger for any 64 bit .Net 4.5 (and up) Windows desktop (maybe other app types, untested) app. (Yes, I know there is Log4Net, this was a fun little project, and well suited for my needs).
  • PercentileCalculator: To get a percentile for a full population of values. No example available yet.
  • RemoteDesktop: Enables using the default Windows RDP client from within your app.
  • SerializationHelper: Helper class for encoding/decoding strings and objects, gzip and deflate compression included. No example available yet.
  • StringTree: A tree of strings, each tree can have multiple sub trees. Leaf nodes can have a string value. Values can get combined using a delimiter. You can use this as an Abstract Syntax Tree for your own lexing logic. No example available yet.
  • StringUtil: String helper class. With this you can generate names and format numeric values.
  • SynchronizationContextWrapper: A wrapper for SynchronizationContext, so SynchronizationContext is available throughout the entire application. A SynchronizationContext is for synchronizing data to another thread, for instance to the main thread. Handy if you want to update a System.Windows.Forms.Label from another thread. It is the most reliable way to do something like that IMHO.
  • TimeSeriesStore: This is a very simple time series store implementation. It is a partioned key value store with a timestamp (DateTime) for a key and an object[] for values. If you do not specify a partition in the different functions, the default is used. You can use the instance if you want one general time series store. If you want something more robust and distributed I suggest that you take a look at OpenTSDB, Redis, etc. No example available yet.
  • Tracert: Like the cmd tool.

Winforms examples available.

To come:
  • More examples.


Third party stuff I use(d), worth mentioning:
  • A cross domain cookie decoder: .Net does not accept cross domain cookies, therefore I use my implementation of this http://docs.jboss.org/netty/3.2/xref/org/jboss/netty/handler/codec/http/CookieDecoder.html. My implementation will be available to download, if the original author is ok with it.
  • FastSerializer: Binary serialization can be a major pain in the ass. The default serialization stuff in .net is way too slow and way too much gets serialized (if you do not do a clean implementation, but still, for complicated datastructures this is very difficult). That's why I use FastSerializer of Tim Haynes (URL to follow). You need a bit of boilerplate code in each class for the objects to serialize, but you get a clean output.
  • SpecialFolder: Lists special folders, like Desktop. http://www.gotdotnet.ru/Forums/Common/130375.aspx
  • GlassTextBox: I made my own implementation named CueTextBox based on this Winforms control http://nate.deepcreek.org.au/svn/tools/ComskipToCuttermaran/trunk/CSharpControls/GlassTextBox.cs. My implementation will be available to download, if the original author is ok with it.

Last edited Jun 15, 2016 at 1:37 PM by Didjeeh, version 26