ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Extract bold letters in a cell (https://www.excelbanter.com/excel-worksheet-functions/78469-re-extract-bold-letters-cell.html)

Stefi

Extract bold letters in a cell
 
It can be solved with a UDF:

Function ExtrBold(str)
ExtrBold = ""
For s = 1 To Len(Range(str).Value)
If Range(str).Characters(1, s).Font.Bold Then
ExtrBold = Left(Range(str).Value, s)
Else
Exit Function
End If
Next s
End Function

Usage:

=ExtrBold(ADDRESS(1,1,4,1))

where ADDRESS(1,1,4,1) refers to cell A1

Regards,
Stefi

€žhbamse€ť ezt Ă*rta:

Hello!
I have a great list of names in a column.
The names are in bold letters, and the titles is in normal letters.

Is there a way to extract only the bold letters from these cells?

I have spent a few hours searching for this but haven't seen any solutions
for it.

Most thankful
/Henrik




All times are GMT +1. The time now is 07:03 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com