Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 14
Default How to test a cell for the strikethrough effect?

What formula, if any, would return, say, "true" or "false", for the presence
of the strikethrough effect on text in a given cell?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default How to test a cell for the strikethrough effect?

No formula can return formats.

Try this macro.

Make sure you have an empty column to the right of the selected cells.

Sub Strike_Through()
For Each cell In Selection
If cell.Font.Strikethrough = True Then
cell.Offset(0, 1).Value = "TRUE"
Else: cell.Offset(0, 1).Value = "FALSE"
End If
Next cell
End Sub


Gord Dibben MS Excel MVP


On Wed, 27 Sep 2006 14:28:01 -0700, Ricter
wrote:

What formula, if any, would return, say, "true" or "false", for the presence
of the strikethrough effect on text in a given cell?


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,688
Default How to test a cell for the strikethrough effect?

No formula can return formats.

It can be done with a named formula that uses GET.CELL but a UDF or macro is
easier to work with.

Biff

"Gord Dibben" <gorddibbATshawDOTca wrote in message
...
No formula can return formats.

Try this macro.

Make sure you have an empty column to the right of the selected cells.

Sub Strike_Through()
For Each cell In Selection
If cell.Font.Strikethrough = True Then
cell.Offset(0, 1).Value = "TRUE"
Else: cell.Offset(0, 1).Value = "FALSE"
End If
Next cell
End Sub


Gord Dibben MS Excel MVP


On Wed, 27 Sep 2006 14:28:01 -0700, Ricter

wrote:

What formula, if any, would return, say, "true" or "false", for the
presence
of the strikethrough effect on text in a given cell?




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
Help with this conditional IF statement C-Dawg Excel Discussion (Misc queries) 3 May 15th 06 06:01 PM
Conditional Formatting to Test Value in Cell Carroll Excel Worksheet Functions 3 March 9th 06 07:38 PM
IF Function to test formula in a cell Fred Holmes Excel Worksheet Functions 5 November 18th 05 12:04 AM
hpw do I logic test a cell then copy the row to diff. SS Debi Excel Worksheet Functions 4 October 5th 05 09:42 PM
Possible Lookup Table Karen Excel Worksheet Functions 5 June 8th 05 09:43 PM


All times are GMT +1. The time now is 08:15 PM.

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

About Us

"It's about Microsoft Excel"