LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
markx
 
Posts: n/a
Default Checking excel for errors/inconsistencies

Hi folks,

I'm trying to check my worksheets for errors and inconsistencies. For this,
I thought to use some VBA code that would color the cells depending on if
the content is the text, number, formula, reference, etc...

I've already found the code for "formula-testing" (provided by Gord Dibben)
which is like this:
---
Sub colorcells()
Dim Cel As Range
For Each Cel In ActiveSheet.UsedRange
If Cel.HasFormula Then
Cel.Interior.ColorIndex = 24 '''-4142 for "No Fill"
End If
Next
End Sub
---

I would like to incorporate the test for other contents (with different
colors), but apparently there is no such thing as "Cel.HasReference" or
"Cel.HasText". For sure, I will explore VBA by myself, but some help from
your side would be greatly appreciated!

Mark

PS: If you think that there are some other tests that may prove quite
useful, pls don't hesitate to suggest it he-)


 
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
I get a program error when I download an excel template Ladybug Excel Discussion (Misc queries) 3 March 4th 05 12:02 AM
html to excel nellie Excel Discussion (Misc queries) 4 February 8th 05 10:37 PM
Excel error - Startup (and Acrobat PDFMaker) gxdata Setting up and Configuration of Excel 0 February 4th 05 03:44 AM
Merge from Excel to Excel dalstar Excel Discussion (Misc queries) 3 January 30th 05 02:37 PM
Why does spelling check close Excel when checking spanish? RCP Excel Discussion (Misc queries) 2 December 4th 04 07:37 PM


All times are GMT +1. The time now is 05:28 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"