Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How Do You Compare Strings In C#?
Message
From
07/01/2005 13:09:11
 
General information
Forum:
ASP.NET
Category:
Coding, syntax and commands
Miscellaneous
Thread ID:
00975060
Message ID:
00975201
Views:
17
I'm not into football, but have a great time at the Packers game. I'll probably relax with a little x-country skiing this weekend ... we're supposed to get maybe a half foot of snow by tomorrow, and it's snowing pretty heavily right now.

~~Bonnie



>>Einar,
>>
>>>>I guess it doesn't really make sense to check if a sring is less or greater than another string.
>>If you have a specific senario where comparing strings are usefull please post and I can take a look at it.<

>>
>>Of course it makes sense ... when you're sorting things alphabetically. And you use the string.Compare(s1, s2) method. See my reply to Kevin.
>>
>>~~Bonnie
>
>Bonnie,
>Yeah I guess you are correct. I didn't think of that (I have been having a lot of those moments this week good thing it is weekend soon and I can go relax at the Packer game).
>I would assume the comparison of strings would be based on their ascii value.
>
>Einar
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Previous
Reply
Map
View

Click here to load this message in the networking platform