Home |
Search |
Today's Posts |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I don't have another guess why it didn't work:
Option Explicit Sub Fill_down_CD() Application.DisplayAlerts = False Dim wks As Worksheet Dim Rng As Range Dim LastRow As Long Set wks = ActiveSheet With wks Set Rng = .UsedRange LastRow = .Cells.SpecialCells(xlCellTypeLastCell).Row On Error Resume Next Set Rng = .Range("C2:D" & LastRow).Cells.SpecialCells(xlCellTypeBlanks) On Error GoTo 0 If Rng Is Nothing Then Exit Sub Else Rng.FormulaR1C1 = "=R[-1]C" End If With .Range("C:D") .Value = .Value End With End With Application.DisplayAlerts = True End Sub "J.W. Aldridge" wrote: ....no merged cells... same as all the previous ones that worked.. -- Dave Peterson |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Error handling error # 1004 Run-time error | Excel Programming | |||
Error Handling - On Error GoTo doesn't trap error successfully | Excel Programming | |||
Form Err.Raise error not trapped by entry procedure error handler | Excel Programming | |||
Automation Error, Unknown Error. Error value - 440 | Excel Programming |