Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
This code is not working for me...I want to cycle through each sheet in
my workbook and run and IF statement. It is not cycling through my sheets, please help! TIA! - mike Range("A1").Select Selection.End(xlDown).Select Dim TodaysDate TodaysDate = ActiveCell.Text Dim WbMain As Workbook Dim wb As Workbook Dim Sh As Worksheet Application.ScreenUpdating = False Application.EnableEvents = False Set WbMain = ActiveWorkbook For Each Sh In WbMain.Worksheets Range("A1").Select Selection.End(xlDown).Select If ActiveCell.Value = TodaysDate Then Range("A1").End(xlDown).Offset(1, 0).FormulaR1C1 = "=today()" Range("A1").End(xlDown).Offset(0, 1).Formula = "0" Columns("A:A").Select Selection.Copy Selection.PasteSpecial Paste:=xlPasteValues Range("A1").Select End If Next Sh *** Sent via Developersdex http://www.developersdex.com *** |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Tab keeps cycling through the same row | Excel Discussion (Misc queries) | |||
Cycling through workbooks | Excel Discussion (Misc queries) | |||
cycling through columns? | Excel Programming | |||
Cycling through variables. | Excel Programming | |||
Cycling through worksheets | Excel Programming |