R1C1 dynamic range syntax error

doodlecat

New Member
Joined
Feb 15, 2013
Messages
5
Can anyone please tell me why the R1C1 formula line is giving me syntax error? I am using excel 2003. I have a dynamic range of data on report tab and trying to copy from ABC pivot table (on ABC pivot tab) to the report tab starting at the end of the dynamic range of data. I am trying to auto fill the blank cells from pivot table on the report tab using the "if" formula. Hope this is clear..
Thanks a lot!!!

Dim RowCount As Long, myCountRange As Range

Set myCountRange = Columns("C:C")
RowCount = Application.WorksheetFunction.CountA(myCountRange)
ActiveCell.FormulaR1C1 = "=IF('ABC Pivot'!R["&-RowCount&"]C="",Report!R[-1]C,'ABC Pivot'!R["&-RowCount&"]C)"
 

Excel Facts

Workdays for a market open Mon, Wed, Friday?
Yes! Use "0101011" for the weekend argument in NETWORKDAYS.INTL or WORKDAY.INTL. The 7 digits start on Monday. 1 means it is a weekend.

Forum statistics

Threads
1,223,230
Messages
6,170,883
Members
452,364
Latest member
springate

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top