|
-
May 5th, 2005, 12:05 PM
#1
Thread Starter
New Member
Run-time error '1004': Application-defined or object-defined error
Hi,
Another novice problem from me.
I get this error message:
Run-time error '1004':
Application-defined or object-defined error
This is the statement that is highlighted when the error comes up.
ActiveCell.FormulaR1C1 = "=Average(R[6]C[-2]:R[myDatasecs+6]C[-2])"
Here is the code block:
Set currentCell = Range("Q11")
For n = 1 To 10
currentCell.Value = myOscArray(n, 1)
currentCell.Offset(0, 1).Value = myOscArray(n, 2)
currentCell.Offset(0, 2).Formula = "=RC[-2]-RC[-1]"
Set nextCell = currentCell.Offset(1, 0)
Set currentCell = nextCell
Next n
Range("E6").Select
ActiveCell.FormulaR1C1 = "=Average(R[6]C[-2]:R[myDatasecs+6]C[-2])"
Range("F6").Select
ActiveCell.FormulaR1C1 = "Mean Flow"
Thanks in advance,
Neil
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|