Using custom type converters with C# and YamlDotNet, part 2
Recently I discussed using type converters to perform custom serialization of types in YamlDotNet. In this post I'll concentrate on expanding the type converter to support deserialization as well.I'll...
View ArticleTranslating text with Azure cognitive services
Some time ago, I used the Bing Translator API to help create localization for some of our products. As Microsoft recently retired the Data Market used to provide this service it was high time to...
View ArticleRestoring missing Authorization header when using PHP with Apache
I was recently looking into using our Mantis Bug Tracker instance to automatically generate product road-maps - now that we are actually starting to properly plan product updates and as keeping them up...
View ArticleAnnouncing MantisSharp, a .NET client for using the MantisBT REST API
I've released a new open source project named MantisSharp, a simple .NET client for working with the recently introduced REST API for Mantis Bug Tracker.The library is just getting started and is...
View ArticleWriting custom Markdig extensions
Markdig, according to its description, "is a fast, powerful, CommonMark compliant, extensible Markdown processor for .NET". While most of our older projects use MarkdownDeep (including an increasingly...
View ArticleCapturing screenshots using C# and p/invoke
I was recently updating some documentation and wanted to programmatically capture some screenshots of the application in different states. This article describes how you can easily capture screenshots...
View ArticleGetting a window rectangle without the drop shadow
In my last article, I describe how to use the Win32 API to capture screenshots of the desktop. There was one frustrating problem with this however - when capturing an image based on the value of the...
View ArticleSending SMS messages with Twilio
Last week I attended the NEBytes technology user group for the first time. Despite the fact I didn't actually say more than two words (speaking to a real live human is only marginally easier than...
View ArticleWorking around System.ArgumentException: Only TrueType fonts are supported....
One of the exceptions I see with a reasonable frequency (usually in Gif Animator) is Only TrueType fonts are supported. This is not a TrueType font.System.ArgumentException: Only TrueType fonts are...
View ArticleTargeting multiple versions of the .NET Framework from the same project
The new exception management library I've been working on was originally targeted for .NET 4.6, changing to .NET 4.5.2 when I found that Azure websites don't support 4.6 yet. Regardless of 4.5 or 4.6,...
View ArticleWorking around "Cannot use JSX unless the '--jsx' flag is provided." using...
I've been using the utterly awesome ReactJS for a few weeks now. At the same time I started using React, I also switched to using TypeScript to work with JavaScript, due to it's type safety and less...
View ArticleReading Adobe Swatch Exchange (ase) files using C#
Previously I wrote how to read and write files using the Photoshop Color Swatch file format. In this article mini-series, I'm now going to take a belated look at Adobe's Swatch Exchange file format and...
View ArticleWriting Adobe Swatch Exchange (ase) files using C#
In my last post, I described how to read Adobe Swatch Exchange files using C#. Now I'm going to update that sample program to save ase files as well as load them.Writing big endian valuesI covered the...
View ArticleRotating an array using C#
I've recently been working on a number of small test programs for the different sections which make up a game I'm planning on writing. One of these test systems involved a series of polyominoes which I...
View ArticleTools we use - 2015 edition
Happy New Year! It's almost becoming a tradition now to list all of the development tools and bits that I've been using over the past year, to see how things are changing. 2015 wasn't the best of years...
View ArticleReading and writing farbfeld images using C#
Normally when I load textures in OpenGL, I have a PNG file which I load into a System.Drawing.Bitmap and from there I pull out the bytes and pass to glTexImage2D. It works, but seems a bit silly having...
View ArticleGenerating code using T4 templates
Recently I was updating a library that contains two keyed collection classes. These collections aren't the usual run-of-the-mill collections as they need to be able to support duplicate keys. Normally...
View ArticleSQL Woes - Mismatched parameter types in stored procedures
We had a report of crashes occurring for certain users when accessing a system. From the stack data in the production logs, a timeout was occurring when running a specific stored procedure. This...
View ArticleImplementing events more efficiently in .NET applications
One of the things that frequently annoys me about third party controls (including those built into the .NET Framework) are properties that either aren't virtual, or don't have corresponding change...
View ArticleAdding keyboard accelerators and visual cues to a WinForms control
.syntax {max-height: 25em;}Some weeks ago I was trying to make parts of WebCopy's UI a little bit simpler via the expedient of hiding some of the more advanced (and consequently less used) options....
View Article