gXLWorkSheet := gXLWorkbook.Worksheets.Add(); gXLWorkSheet.Name := gT218; gXLWorkSheet.Activate; gXLWorkSheet.Range('A1').Value := FORMAT(UPPERCASE(gT218)); gXLWorkSheet.Range('A1').Font.Bold := TRUE; gXLWorkSheet.Range('B3').Value := FORMAT(DebAdr[1]); gXLWorkSheet.Range('B4').Value := FORMAT(DebAdr[2]); gXLWorkSheet.Range('B5').Value := FORMAT(DebAdr[3]); gXLWorkSheet.Range('B6').Value := FORMAT(DebAdr[4]); gXLWorkSheet.Range('B7').Value := FORMAT(DebAdr[5]); gXLWorkSheet.Range('A1').Font.Bold := TRUE; DataRange := 'Datagrundlag!A1:I' + FORMAT(pNoOfRows + 1); gXLPivotCache := gXLApp.ActiveWorkbook.PivotCaches.Add(1,DataRange); gXLPivotCache.CreatePivotTable('','PivotTable1'); gXLPivotTable := gXLWorkSheet.PivotTables('PivotTable1'); gXLPivotTable.Location(gT218+'!A11'); // Pivot data ...
gXLPivotTable := gXLWorkSheet.PivotTables('PivotTable1'); gXLPivotTable.Location(gT218+'!A11');
DataRange := 'Datagrundlag!A1:I' + FORMAT(pNoOfRows + 1); gXLPivotCache := gXLApp.ActiveWorkbook.PivotCaches.Add(1,DataRange); gXLPivotCache.CreatePivotTable('','PivotTable1'); gXLWorkSheet := gXLApp.ActiveSheet; gXLPivotTable := gXLWorkSheet.PivotTables('PivotTable1'); gXLWorkSheet.Name := gT218; gXLRange := gXLWorkSheet.Range('A1'); gXLRange.FormulaR1C1 := UPPERCASE(gT218); gXLRange.Font.Bold := TRUE;