# C#, turn an int into a char



## stu2004 (Nov 24, 2004)

Hi there, I'm new to the language and need a little help
I've got a single digit integer and I need to convert it to a char. 
How do I do this?

Thanks in advance


----------



## Shadow2531 (Apr 30, 2001)

I don't know c# and cannot test, but this might be it.

char bla = Convert.ToChar(9);

Just not sure if that converts 9 to '9' or 9 to a horizontal tab. I think it does the latter. Which one do you want to do?


----------



## the_last_rit (Sep 17, 2004)

actually u cannot convert an int or int16 or int32 to char type safely in c#. u have to use the ToString.method


----------

