Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
If Function, looking for formats in values
How would I write an IF function to check to see if a cell is in Italics and
if it is make another cell = 0 IF(A1???, B1=0) Anyone know what to put where the ?s are? Thanks. |
#2
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
If Function, looking for formats in values
Try this small macro:
Sub routine() If Range("A1").Font.FontStyle = "Italic" Then Range("B1").Value = 0 End If End Sub -- Gary''s Student - gsnu200731 "ManBoy86" wrote: How would I write an IF function to check to see if a cell is in Italics and if it is make another cell = 0 IF(A1???, B1=0) Anyone know what to put where the ?s are? Thanks. |
#3
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
If Function, looking for formats in values
Or try this:
Function IsItalic(mCell As Range) As Boolean IsItalic = mCell.Font.Italic End Function And then type in B1: =IF(IsItalic(A1),0,"Not italic in A1") "ManBoy86" wrote: How would I write an IF function to check to see if a cell is in Italics and if it is make another cell = 0 IF(A1???, B1=0) Anyone know what to put where the ?s are? Thanks. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How to get different text formats in a concatenate function | Excel Discussion (Misc queries) | |||
how to copy only values and formats of worksheets to new workbook | Excel Worksheet Functions | |||
Conditional Formats for formulae and values | Excel Worksheet Functions | |||
Custom number formats in TEXT function | Excel Worksheet Functions | |||
Copy Color Formats Based On Column Date Values | Excel Discussion (Misc queries) |