update...."object required" rt er 424

  • Thread starter Thread starter Kenny
  • Start date Start date
K

Kenny

ok I replaced the bold statement with ...

SET ACTIVESHEET.RANGE(RRANGE2) = RRANGE1.AUTOFILL(RRANGE2,
XLFILLFORMATS AND XLFILLSERIES)


it completes the fill with the correct series ...but I am getting a run
time error 424.... object required?
 
finally figured it out using the "record a macro" feature....very
handy.

working code...

Sub CashFlow()
Dim rRange1 As Range
Dim rRange2 As Range
Dim strDate1 As String
Dim strDate2 As String

Set rRange1 = Application.InputBox("2 cells", , , , , , , 8)
Set rRange2 = Application.InputBox("total range", , , , , , , 8)
strDate1 = Application.InputBox("1st date", , , , , , , 2)
strDate2 = Application.InputBox("pattern date", , , , , , , 2)

[rRange1] = Array(strDate1, strDate2)
rRange1.Select
Selection.AutoFill Destination:=rRange2, Type:=xlFillDefault
rRange2.Select

End Sub
 
Back
Top