Click here to Skip to main content
13,560,107 members
Click here to Skip to main content

Tagged as


2 bookmarked
Posted 14 Feb 2011
Licenced CPOL

How to Toggle String Case in .NET

, 14 Feb 2011
What about this?string s = new string(( from c in "ABCdef" select char.IsUpper(c) ? char.ToLower(c) : char.ToUpper(c) ).ToArray());Note by Alexander Bell: In regards to the performance, this one (i.e. Alternate 9) is the worst in comparison...



Compare Revision Minor Date Status Editor
2 - publicly available No 14-Feb-11 15:39 Available DrABELL
1 No 14-Feb-11 12:58 Composing TimB99


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Software Developer
New Zealand New Zealand
This member doesn't quite have enough reputation to be able to display their biography and homepage.

You may also be interested in...

Permalink | Advertise | Privacy | Cookies | Terms of Use | Mobile
Web03-2016 | 2.8.180527.3 | Last Updated 14 Feb 2011
Article Copyright 2011 by TimB99
Everything else Copyright © CodeProject, 1999-2018
Layout: fixed | fluid