Thread: Help with Macro
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Robert B. Robert B. is offline
external usenet poster
 
Posts: 26
Default Help with Macro

Dear All,

I have the following partial code below for selecting data from
Visitor_In_Out (worksheet) based on if somebody is either in or out (1 or 0).
The problem I am having is when nobody in list is in (1) report shows all
individuals in list. How can this be corrected to show zero in report that
is created?

Thanks for any help

Robert B.


Application.ScreenUpdating = False
Sheets("Visitor_Cont_OnSite").Select
Application.Run "I_O_Log.xls!Visitor_Cont_OnSite_Clear_Sheet"
Sheets("Visitor_In_Out").Select
Application.Run "I_O_Log.xls!Visitor_Unhide_Columns"
Rows("7:7").Select
Range("DZ7").Activate
Selection.AutoFilter
Range("ct7").Select
Selection.AutoFilter Field:=98, Criteria1:="1", Operator:=xlAnd