How to enter Celsius symbol in to a lable VS2008

Mike Eghtebas
Mike Eghtebas used Ask the Experts™
on
In vb.net 2008, I have a label on a form. Instead of the word celsius, I want to enter its symble (small circle followed by letter C).

Ho do I do this? What font type and what combination to enter in the lable's text property?

Thank you.
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
QCD

Commented:
On a PC running Windows, you can access the degree symbol as ALT+0176.  It should be available with most fonts.

Alternatively, you may open the Character Map program, and copy it.

Hope this helps.
Mike EghtebasDatabase and Application Developer

Author

Commented:
It is differnt in vb.net

I was able to produce ALT+0176 in the word environment. If you are able to do it in vb environment please let me know how.

Thanks
Mike

Commented:
alt-0176 doesn't work but CharMap works fine for me.
Learn Ruby Fundamentals

This course will introduce you to Ruby, as well as teach you about classes, methods, variables, data structures, loops, enumerable methods, and finishing touches.

Most Valuable Expert 2013

Commented:
° in UTF = Chr(167)
or Unicode = (U+00B0)
Mike EghtebasDatabase and Application Developer

Author

Commented:
re>: ° in UTF = Chr(167)

What UTF stands for?

I am using:


lblLow.Text = Chr(167) & "C"

Is not the best option to use code to populate a lable nevertheless. It comes back with
another character + C

In vb 2008, there is no Unicode option for fonts.

Wingding etc my be the solution but I need to know the sequence of the characters to produce what I want. My search continues.
Most Valuable Expert 2013

Commented:
UTF = Unicode Transformation Format so not much help - sorry.
 
What about &#176  ?
above solutions will work otherwise use image.
QCD

Commented:
Unicode is unnecessary for the degree symbol, as it is part of the extended ASCII table.  If you are simply unable to produce the character in the VB development environment, then you should cut and paste it from a different application (such as character map).
>>It is differnt in vb.net

I don't think it is. ALT+0176 works fine for me in Visual Studio 2008 and 2010.

Wayne
Mike EghtebasDatabase and Application Developer

Author

Commented:
Wayne,

Do you enter into directly in to text property?
There is always the possibiliy that it is due to your Computer not supporting this. Which OS do you have. Chances are that although it may not show on your Computer it could on others'. Remember you can always Copy+Paste ° in the label if you have to.

Try:

lblLow.Text = "°C"
>>Do you enter into directly in to text property?

Yes. Press and hold the ALT key, then, in sequence, key in 0176 on the numeric keypad. The symbol will only appear once you've released the ALT key.
Naman GoelPrincipal Software engineer
Commented:
use following  
lblLow.Text= "15\u00b0C";
This will show 15 small 0 and C

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial