Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3
Default Conditional formatting if a cell contains a formula

I would like to apply conditional formatting if a cell contains a formula as
opposed to an entered number. I would think that is doable somehow using a
Formula Is condition, but I have not been able to figure it out. I thought
the cell function might be the one to use, but all I can see is being able to
evaluate if the cell contains a value, text or blank. The formula results in
a value, and an input number is a value, so going that route hasn't panned
out. If anybody has any suggestions, please let me know!

Thanks,
Tim
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,501
Default Conditional formatting if a cell contains a formula

Hi,

Try this. Alt +f11 to open vb editor. Right click 'This Workbook' and paste
the code below in.

The select your cell (say A1)and
Format|Conditional format
Formula is
=isformula(a1)
Pick a colour
OK

use format painter to copt the CF to other cells.


Function ISFORMULA(c As Range) As Boolean
ISFORMULA = c.HasFormula
End Function

Mike

"tsbarr" wrote:

I would like to apply conditional formatting if a cell contains a formula as
opposed to an entered number. I would think that is doable somehow using a
Formula Is condition, but I have not been able to figure it out. I thought
the cell function might be the one to use, but all I can see is being able to
evaluate if the cell contains a value, text or blank. The formula results in
a value, and an input number is a value, so going that route hasn't panned
out. If anybody has any suggestions, please let me know!

Thanks,
Tim

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,766
Default Conditional formatting if a cell contains a formula

Hi,

You may also try this

Go to insert name (name the formula as €ścellhasformula€ť) and in the €śRefers
to€ť box, type the following formula = get.cell(48,indirect(€śrc€ť,false)).
Now in the conditional formatting dialog box, type =cellhasformula in the
"Formula is". Use the desired formatting.

--
Regards,

Ashish Mathur
Microsoft Excel MVP
www.ashishmathur.com

"tsbarr" wrote in message
...
I would like to apply conditional formatting if a cell contains a formula
as
opposed to an entered number. I would think that is doable somehow using
a
Formula Is condition, but I have not been able to figure it out. I
thought
the cell function might be the one to use, but all I can see is being able
to
evaluate if the cell contains a value, text or blank. The formula results
in
a value, and an input number is a value, so going that route hasn't panned
out. If anybody has any suggestions, please let me know!

Thanks,
Tim


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Conditional formatting to a different cell and it contains a formula Rick[_10_] Excel Worksheet Functions 7 July 16th 08 06:22 PM
Conditional Formatting on cell with a formula Kass Excel Worksheet Functions 5 September 30th 07 08:30 AM
Is conditional formatting or formula possible by cell color? J Billy Excel Worksheet Functions 2 June 30th 07 04:43 AM
Recognizing Cell Formatting To Use In A Formula Or Conditional For Jim J. Excel Worksheet Functions 0 September 20th 06 08:28 PM
Conditional Formatting if cell content is a formula oldsambvca Excel Worksheet Functions 2 June 6th 06 10:24 PM


All times are GMT +1. The time now is 11:31 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"