View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Gord Dibben Gord Dibben is offline
external usenet poster
 
Posts: 22,906
Default uisng two paramaters for conditional formatting / Limiting screen size

Answer for #1

Don't use red background color for the alternate rows.

Try a lighter color and employ the regular FormatCellsNumberNumber red font
for negatives.

Answer for #2

You can set the allowable scrolling area using VBA code.

Since the scrollarea method does not stick between sessions you will have to
reset it each time you open the workbook.

You may wish to place the code into a WorkBook_Open Sub in ThisWorkbook module
and specify which worksheet if only one sheet required.

Adjust the sheetname and range to suit.

Private Sub WorkBook_Open()
Sheets("YourSheet").ScrollArea = "A1:K27"
End Sub

Or also in the Thisworkbook module to limit scrollarea on all sheets.

Private Sub Workbook_SheetActivate(ByVal Sh As Object)
With ActiveSheet
.ScrollArea = "A1:K27"
End With
End Sub


Gord Dibben MS Excel MVP

On Sun, 20 May 2007 04:16:38 +0100, Colin Hayes
wrote:


Hi

I have a couple of small questions :

1. The first one is to do with using more than one condition in
conditional formatting without having once countermand the other.

I'm using =MOD(ROW(),2)=0 to colour alternate rows down my worksheet.

I'm also trying to have negative numbers show in red by using formula -
less then zero - font red.

I can't , whatever I do , get this to work so that negative numbers will
be red on whichever row they appear , without changing the background
colour. Any suggestions?

2 . Also , I would like to limit the visible screen size to A1 - K27 ,
so that the visible screen won't scroll beyond these rows. Is there a
piece of code I can enter to do this?

Any help gratefully received.

Thanks.