ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Help with Macro (https://www.excelbanter.com/excel-programming/401767-help-macro.html)

Robert B.

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



All times are GMT +1. The time now is 06:03 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com