Consulting

Results 1 to 3 of 3

Thread: Solved: Range autofill

  1. #1

    Solved: Range autofill

    Hi all,

    I have a little problem with my vb code, I am trying to autofill a formula within a range.

    here is my code:

    [vba] FSun = Cells.Find("Sunday", ActiveCell, xlValues, xlPart, xlByRows, xlNext, False).Select
    FSunrow = ActiveCell.Row
    FSuncol = ActiveCell.Column

    LastConcatrow = GetLast(ActiveSheet, True)
    LastConcatcol = GetLast(ActiveSheet, False)
    LastConcatCell = Cells(LastConcatrow, LastConcatcol).Select

    fzero = Cells(FSunrow + 2, FSuncol).Select
    ActiveCell.FormulaR1C1 = "=CONCATENATE('CCL (2)'!RC&CCL!RC)"

    'it is this bit that comes up with an error
    Range(fzero).AutoFill Destination:=Range("fzero", "LastConcatCell")[/vba]

    Are there any suggestions? thanks.

  2. #2
    Distinguished Lord of VBAX VBAX Grand Master Bob Phillips's Avatar
    Joined
    Apr 2005
    Posts
    25,453
    Location
    Can you post the workbook?
    ____________________________________________
    Nihil simul inventum est et perfectum

    Abusus non tollit usum

    Last night I dreamed of a small consolation enjoyed only by the blind: Nobody knows the trouble I've not seen!
    James Thurber

  3. #3
    sorted thanks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •