Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Simple Question
My fault... I had the Instr arguments backwards... Sorry about that
Sub DeleteSheets() Dim wks As Worksheet On Error GoTo ErrorHandler Application.DisplayAlerts = False For Each wks In Worksheets If InStr(UCase(wks.Name), "BILL") 0 Then wks.Delete Next wks ErrorHandler: Application.DisplayAlerts = True End Sub -- HTH... Jim Thomlinson "Eric" wrote: Hi guys, How do I get my code to work if the activecell is in Column J, I'll need to go back 3 columns and down one row? My code below doesn't work. If Columns("J:J") Then ActiveCell.Offset(1,-3).Select |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Simple Question
Disregard this... It is a response to a different thread. I must be losing it
(assuming I had it in the first place) -- HTH... Jim Thomlinson "Jim Thomlinson" wrote: My fault... I had the Instr arguments backwards... Sorry about that Sub DeleteSheets() Dim wks As Worksheet On Error GoTo ErrorHandler Application.DisplayAlerts = False For Each wks In Worksheets If InStr(UCase(wks.Name), "BILL") 0 Then wks.Delete Next wks ErrorHandler: Application.DisplayAlerts = True End Sub -- HTH... Jim Thomlinson "Eric" wrote: Hi guys, How do I get my code to work if the activecell is in Column J, I'll need to go back 3 columns and down one row? My code below doesn't work. If Columns("J:J") Then ActiveCell.Offset(1,-3).Select |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
IF formula-simple question; simple operator | Excel Discussion (Misc queries) | |||
a simple question | Excel Discussion (Misc queries) | |||
Simple Simple Excel usage question | Excel Discussion (Misc queries) | |||
simple question, hopefully a simple answer! | Excel Programming | |||
Simple Question | Excel Programming |