View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
S Himmelrich S Himmelrich is offline
external usenet poster
 
Posts: 76
Default Calculating column based on formula

I'm getting an "Application-defined or object-defined error" on the
line below that I've identified...can anyone help me out on this?


Dim last7 As Long
last7 = Worksheets("Working Sheet").Cells(Rows.Count,
"J").End(xlUp).Row
Range("K1").Formula = "=IF(SUM('Working Sheet'!RC[1]/MACRO!G
$11$)),"",SUM('Working Sheet'!RC[1]/MACRO!G$11$)" <---LINE WITH ERROR
Range("K1").AutoFill Destination:=Range("K1:K" & last7)