Excel Macro to auto fill formula : I want to create an Excel macro that can expand my formula on a column with different sizes.

I currently have 2 Pivot Tables and at the end of each one I have created a column of concatenated values.
Eg:
 - Table 1: Cols D:I , concatenated col J
   First Cell with formula is J12 (=CONCATENATE(D12;E12;F12;G12))
 - Table 2: Cols O:T , concatenated col U
   First Cell with formula is U12 (same as before)

I want to be able to press a button after refreshing the tables that will delete cols J and U and fill them with the formula again according to the tables' ranges.

I have created tried codes like
Range("J12:M" & LastRow).Formula = "=CONCATENATE ... " 
but it is not working.

Thank you in advance

