Don't Break The Build Software development articles and tutorials

28Oct/130

Reading XML With C# And XmlDocument

I have started publishing a book over at LeanPub that covers handling XML with C# entitled C# And XML: A Primer. I figured why not let the good readers of my blog enjoy some of what is in the book? Below is how to read XML with the XmlDocument class.

Tagged as: , No Comments
30Jul/130

Basic Parsing in Scala Using Parsing Combinators

Basic Parsing In Scala

In my quest to become a compiler developer I have been learning about parsing and lexical analysis. Recently I have discovered the power of Scala's parser combinator library, which has been a joy to use. When you partner that with their case classes, it becomes incredibly easy to create a small parser. In this tutorial, we will create a basic arithmetic parser.

Tagged as: , No Comments
3Jan/132

My month long Windows Phone 8 ‘experiment’

Why Windows Phone 8?

My previous phone was an HTC Evo 4G and was using Sprint as my carrier. I was becoming incredibly frustrated with Sprint and their network, feeling like i was paying 100% for a 66% of the service. I couldn't make calls and if I was lucky enough for the call to go through, it was only a matter of time before it dropped. My contract was up on 12/8/2012 and I was looking at new phones.

Tagged as: 2 Comments
1May/120

Learning CIL Series – Part 3 – Branching

In Part 1 of the series we dove into the very basics of getting an application up and running in CIL. Part 2 covered methods in CIL and how to call and create our own methods. This part of the series is going to cover branching our CIL code. Branching is a very important concept in CIL because it is what allows us to have loops and control over our program flow

Tagged as: , No Comments
16Mar/121

Reading Excel Column Names In C# using Excel.Interop

The other day I came across an interesting question on StackOverflow asking how to get column names using Excel Interop in .NET and I set out to find the answer. It is a unique question because many people don't care what column (as in letter, so "A","B", "ZZ", etc) their data is in and may dedicate the first row to friendly column headers (as you can't change the defaults in Excel). This is what I came up with:

Tagged as: , , 1 Comment
14Mar/120

One Liner Removing Non-Numerics From String – No Regex Required

I was inspired by Replacing strings using regex in .NET question on StackOverflow today and got to thinking if I would be able to do this without Regex. Then I was even more inspired by the comment by djdanlib:

Sounds like you want a one-liner, but the problem is such that you need two lines. This doesn't seem like it would be too bad if you could first use a regex.replace to remove non-numeric characters, then run a match on an 'all numeric characters?' expression. You could probably switch your UI to use a masked text box and save a lot of trouble, though

Could I do this in one line?

Tagged as: , , No Comments
17Feb/120

Learning CIL Series – Part 2

In part 1 of the series we went over the "Hello World" in CIL. This post will cover creating and calling methods as well as introducing a few more instructions. We will be getting input from the user, an integer, and then adding 10 to it, in a method we create, and then display it on the screen. Let's get started!

Tagged as: , No Comments
16Feb/121

Learning CIL Series – Part 1

This begins part 1 of a many part series on the Common Intermediate Language (formely known as MSIL) which I will refer to as CIL from now on. CIL is the assembly language of the .NET platform and is what all .NET languages ultimately get boiled down to. My reason for doing these tutorials is simple, I want to learn more about CIL and the .NET internals and what better way to do that than blogging and teaching others. Why do I want to learn about .NET internals as well as CIL? I’m creating a programming language that I want to target the .NET framework and I don’t want to be constrained by C#.

Tagged as: , 1 Comment
10Jan/120

In Response To: Iterating Over A Tuple

Today I saw Tombatron's blog post on Iterating Over A Tuple about ways to iterate over a Tuple. While I must say it is a very bad idea to do this (if you want to store your data in something iterable, then use something other than a Tuple), I found a very interesting challenge in this.

Tagged as: No Comments
9Jan/120

Combinator Extension Method Initial Commit

The initial commit of my combinator extension methods is up at github, so please check it out at my github page