What kind of error do you get when it crashes?

To adjust your output to strings, you can use:

Code:
.ToString("F12")
Where the 12 in this case represents the number of places after the decimal point.

Here is a pretty good description on the tostring method:

http://www.blackwasp.co.uk/CSharpNumericToString.aspx