View Single Post
  #10   Report Post  
Posted to microsoft.public.excel.misc
Ed Davis[_2_] Ed Davis[_2_] is offline
external usenet poster
 
Posts: 67
Default Conditional Format

Hi Gord
I put my issue on OZgrid and this was the reply I got:

REPLY:

Unless its a limitation of conditional formatting, I do believe you found a
bug.
I reproduced this as you described.
If I record a macro to unhide the rows... the rows unhide fine.
Produces the following code
Cells.EntireRow.Hidden = False 'this will unhide all rows and columns.
However, if I run that macro afterwards, it fails on that line - no error.
Just stops running.
This does not appear to be related to locked cells/protected sheets.
When I removed the conditional formatting, the above code worked fine.
In fact, I changed the conditional formatting to look like
=LEN(E7)=0
And this actually allowed the cells.entirerow.hidden to run just fine.
However, when the CF was referencing a UDF function, it failed everytime.
Not sure why... thats why I think its bug. This was on Excel 2007.

Thanks,
Ger
END OF REPLY


"Gord Dibben" <gorddibbATshawDOTca wrote in message
...
It is not the UDF and CF that is a problem.

You have something else that is disrupting your macros.


Gord

On Thu, 8 Oct 2009 07:39:48 -0300, "Ed Davis"
wrote:

Hi Gord
This function that you wrote for me works just the way it should. In most
cases it would be perfect.
I have added it to my library of Sub Routines and Functions.

Function IsFormula(Cell)
IsFormula = Cell.HasFormula
End Function

And then in conditional format
FormatCFFormula is: =NOT(IsFormula(A1)) Format to a color.



I have found however, that I can not run a macro on the worksheets that
have
the conditional formatting using this function.
I have tried several macros after using it and some work properly and some
do not.
I have tried macros that do the following :
These macros do not work.
1. Select all Visible sheets
2. Unhide Columns and or Rows.
3. Hide Columns and or Rows

Macros that have worked with it a
1. Copy worksheets.
2. Copy and Paste Values.
3. Copy and Paste Formats.
4. Copy and Paste Formulas.
5. All Workbook and Worksheet Save functions.
6. Unprotect all Worksheets.
7. Protect all Worksheets.
It appears that any macro that uses the word "HIDDEN" or "VISIBLE" do not
work.

I do want you to know I appreciate all the hard work you have put into
this
and many other topics that you have helped me with.