Welcome to Dream.In.Code
Become a C# Expert!

Join 150,170 C# Programmers for FREE! Get instant access to thousands of C# experts, tutorials, code snippets, and more! There are 2,289 people online right now. Registration is fast and FREE... Join Now!




Illegal character of string?

 
Reply to this topicStart new topic

Illegal character of string?

turtleC++
31 Aug, 2008 - 04:19 PM
Post #1

D.I.C Head
**

Joined: 7 May, 2008
Posts: 57

I'm trying to get a illegal character in string, and I try this @#$%&*()_+s, but all seem legal characters, so I wonder what is illegal character for string?

thanks.

Nevermind I found it. It's comma and period: , .

thanks.

Wait, is it? comma and period, doesn't make sense.

This post has been edited by turtleC++: 31 Aug, 2008 - 04:16 PM
User is offlineProfile CardPM
+Quote Post

Martyr2
RE: Illegal Character Of String?
31 Aug, 2008 - 04:42 PM
Post #2

Programming Theoretician
Group Icon

Joined: 18 Apr, 2007
Posts: 5,660



Thanked: 313 times
Expert In: C/C++, Java, VB, VB.NET, C#, PHP, Web Development, HTML & CSS, Javascript

My Contributions
I can't think of an actual illegal character for strings in C#. Illegal characters are in reference to what the string is used for. Like " & " being illegal in XML if you are using your string to build an XML document. But if you can type it out you can pretty much put it into a string. That includes unicode which always gave previous non-unicode compilers and editors problems. You can put some characters like Chinese into a string and they will come up as boxes on screen, but that just means you need to alter the encoding set. However even this will not cause C# to error out with illegal characters.

Hopefully that is what you are asking. smile.gif
User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic
Time is now: 1/9/09 03:11AM

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter

Live C# Help!

C# Tutorials

Reference Sheets

C# Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month