simple copy from http://bmsconverter.codeplex.com/SourceControl/latest