Learning While Aging

Type special symbols in Visual Studio .NET text editor

Have you ever had this problem that you need to type some special symbols in Visual Studio .NET text editor? Such as ©, ®, ±, à, À, and the list goes on. Of course, if you are working on an ASPX file, you can always use the HTML editor and type in their HTML names or HTML numbers, and Visual Studio .NET will automatically convert them to those special symbols (VS 2005 does a much better job than VS 2003). But what if it is not an ASPX file so you don’t have the HTML editor option? For example, you need to change the copyright information of the assembly in AssemblyInfo.vb or AssemblyInfo.cs as the following screen shot shows:

Assembly Information

How will you insert the copyright symbol in VS text editor? If you type “& copy;” which is the HTML name for ©, the text editor will not convert it, you will have “Copyright & copy; Two Tech Hippos” , instead of “Copyright © Two Tech Hippos”. So how can you then type special characters in VS text editor?

Well, you can always use MS Word and insert a special character, then copy & paste it into the VS text editor. But I don’t think it is the best way. There gotta be another way to do it.

After searching the Internet for a couple of days, I finally found the trick: hold you ALT key, then type in the desired HTML number from you numpad, once you release the ALT key, the special character is converted automatically. For example, to enter the copyright symbol, hold the ALT key, then type number 0, 1, 6, 9 in the order from the numpad, and once you release the ALT key, the special character will be inserted into the place. A nice trick, isn’t it?

Here is a complete list of the HTML codes. With the trick above and the HTML codes, you can type any special characters in the VS text editor.

Please let me know if this small trick helped you.

5 1 vote
Article Rating
Subscribe
Notify of
guest

6 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
nickeeromo
nickeeromo
11 years ago

Thanks.  Exactly what I needed.  It is a little silly that you can't just open the table as in Word, but I suppose this is the "professional" way of doing it, right?  So it will help me to learn the necessary HTML codes.
Thanks again.  Perfect.

Brian
Brian
11 years ago

This was very useful, I needed to put in some non=english characters for a customer and couldn't remember how.

Glenn
Glenn
11 years ago

Thanks! 

Kevin Mote
7 years ago

Nice trick. Unfortunately it does not appear to work with extended characters. For example, the Greek letter beta is 03B2, but if I hold down the ALT key and try to type that, it opens the menu that has ALT-B as its shortcut.

6
0
Would love your thoughts, please comment.x
()
x