View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
jfcby[_2_] jfcby[_2_] is offline
external usenet poster
 
Posts: 121
Default Hide Worksheets, Excel 200 & 2003

Hello Jim,

Thank you for your help. I'm not sure that I understand what you are
asking for but I'll give it a try.

The following code has notes through them describing what they
reference:

Sub HideWorkSheet()

With Workbooks("FF_ZoneBuildingEquipList.xls") _
.Sheets("ZONE 5 - BLDG LIST")
ColD = .Cells(65500, 4).End(xlUp).Row 'cell values are only
numbers formated as text
End With

With Workbooks("Equip_List_FF.xls")
For Each ws In Worksheets
For t = 4 To ColD
CL = Right(Range("C2"), 4) 'cell value is text & numbers formated
as General
CR = Range("D4:D" & ColD).Find(Cells(t, 4), LookIn:=xlValues).Row
'cell values are only numbers formated as text
If CL < CR Then ws.Visible = False
Next t
Next ws
End With

End Sub

I'm not sure how to declare varible types. Could you give me an
example of what a varible is and how to declare it?

jfcby