I have two pieces of code. The first one runs fine, the second one gives the run-time error '1004' Application-defined or object-define error. Could someone help me? As you can see, I am trying to sweep through columns and calculate Fourier transforms.
1st (runs well)
Application.Run "ATPVBAEN.XLAM!Fourier", Worksheets("Red").Range("$A1:A128"), _
Worksheets("Analysis - Red").Range("AV430"), False, False
2nd (run-time error)
i = 1
Application.Run "ATPVBAEN.XLAM!Fourier", Worksheets("Red").Range(Cells(1, i), Cells(128, i)), _
Worksheets("Analysis - Red").Range(Cells(430, 48 + i)), False, False
Bookmarks