Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Questions of Great Import
Well... to me anyways...
O.k. First, is there a faster way to do this: For Each c In ActiveSheet.UsedRange If c.Formula Like "=*" Then c.Font.Italic = True Else c.Font.Italic = False End If Next And second, how do I do something For Each Sheet in Workbooks("This Workbook")? I've tried doing that, and it doesn't seem to be working. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Questions of Great Import
Are you trying to make all cells with formulas italic? If so, use
the following line of code (all on one line) ActiveSheet.UsedRange.SpecialCells(xlCellTypeFormu las).Font.Itali c = True You can iterate through worksheets with code like Dim WS As Worksheet For Each WS In ThisWorkbook.Worksheets ' do something with WS Next WS -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "The Wonder Thing" wrote in message ... Well... to me anyways... O.k. First, is there a faster way to do this: For Each c In ActiveSheet.UsedRange If c.Formula Like "=*" Then c.Font.Italic = True Else c.Font.Italic = False End If Next And second, how do I do something For Each Sheet in Workbooks("This Workbook")? I've tried doing that, and it doesn't seem to be working. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
If Formula great than 7 scenarios | Excel Discussion (Misc queries) | |||
What Formula to use(VBA will be great to) | Excel Discussion (Misc queries) | |||
Help on any part of this would be great | Excel Discussion (Misc queries) | |||
THIS IS A GREAT SITE! THANK YOU!!!! | Excel Discussion (Misc queries) | |||
Great discovery? | Excel Worksheet Functions |