Did the vba syntax for pivot table change, in Excel 2016? This line, first in a block that creates a pivot table, was working under Excel 2010, but does not work now, under Excel 2016/ Windows 10:
ActiveWorkbook.PivotCaches.Create(SourceType:=xlDatabase, SourceData:= _
"Sheet1!R1C1:R" & lnglastrow & "C" & lnglastcol & "", Version:=xlPivotTableVersion14).CreatePivotTable _
TableDestination:="Sheet4!R3C1", TableName:="PivotTable1", DefaultVersion _
:=xlPivotTableVersion14