regex - how can I capitalize words in c# .net -
this question has answer here:
- capitalizing words in string using c# 10 answers
i'm trying capitalize words c# applying this
regex.replace(source,"\b.",m=>m.value.toupper())
it doesn't work.
i want c#:
"this example string".replace(/\b./g,function(a){ return a.tolocaleuppercase()});
output string: "this example string"
the issue need escape search term, involves '\' character. use either @"\b."
or "\\b."
search term.
Comments
Post a Comment