View Single Post
  #5   Report Post  
Posted to microsoft.public.excel,microsoft.public.excel.misc,microsoft.public.excel.worksheet.functions
JMay
 
Posts: n/a
Default How to check for a bold text formating through (in) a formula?

Glad you got your answer.
Please Share - what was the problem before
you solved the it?


"Dmitry Kopnichev" wrote in message
...
Thanks. I know now.
"Dmitry Kopnichev" сообщил/сообщила в новостях следующее:
...
Thanks Bob.
I opened Visual Basic Editor, clicked menu View, Code, and pasted the
Function IsBold(rng As Range) As Boolean
Application.Volatile
IsBold = rng.Font.Bold
End Function
Then clicked save.
The formula =ISBold(A1) gives #NAME? , where A1 is bold text. What is

wrong?
"Bob Phillips" сообщил/сообщила в
новостях следующее: ...
A simple UDF will do it

Function IsBold(rng As Range) As Boolean
Application.Volatile
IsBold = rng.Font.Bold
End Function

and use like

=IF(ISBold(A1),...)

--

HTH

Bob Phillips

(remove nothere from the email address if mailing direct)

"Dmitry Kopnichev" wrote in message
...
Hello experts!
How to check for a bold text formatting through (in) a formula?