regex - how can I capitalize words in c# .net -


this question has answer here:

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

Popular posts from this blog

php - cannot display multiple markers in google maps v3 from traceroute result -

php - Boolean search on database with 5 million rows, very slow -

css - Text drops down with smaller window -