Using Proper case with Brackets/Parentheses

moogthemoog

Board Regular
Joined
Nov 17, 2004
Messages
51
Hi

I'm using Change Event code to convert strings to Proper Case (using vbProperCase), which works fine changing "client name" to "Client Name".
However, where there is a string such as "client name (location)", it just converts to "Client Name (location)" - i.e. it doesn't change the first letter after the parenthesis.

Putting a space between the "(" and "l" does make capitalise the "L", but the layout doesn't look right with a space.

Even if the "(Location)" already uses a capital L, the code changes it to lower case.

Is there another code to use instead of vbProperCase?

Code used is:
Code:
If IsNumeric(Target.Value) = False Then _
Target = StrConv(Target.Text, vbProperCase)

Many thanks,
Jon
 

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!

Watch MrExcel Video

Forum statistics

Threads
1,132,679
Messages
5,654,713
Members
418,149
Latest member
tjanok

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top