返回列表 上一主題 發帖

[發問] excel 2007 錄製的樞紐在2003無法使用

[發問] excel 2007 錄製的樞紐在2003無法使用

請教各位先進

  小弟我在2007錄製的樞紐分析,在2003年無法使用

請問是哪裡有問題呢??

------------------------------------------------------------------------------------------------------------

            Rows("1:1").Select
    Selection.Delete Shift:=xlUp
    Columns("C:D").Select
    ActiveWorkbook.PivotCaches.Create(SourceType:=xlDatabase, SourceData:= _
        "整理!R1C3:R65536C4", Version:=xlPivotTableVersion10).CreatePivotTable _
        TableDestination:="整理!R2C9", TableName:="樞紐分析表1", DefaultVersion:= _
        xlPivotTableVersion10
    Sheets("整理").Select
    Cells(2, 9).Select
    ActiveWorkbook.ShowPivotTableFieldList = True
    With ActiveSheet.PivotTables("樞紐分析表1").PivotFields("料號+批號")
        .Orientation = xlRowField
        .Position = 1
    End With
   
    ActiveSheet.PivotTables("樞紐分析表1").AddDataField ActiveSheet.PivotTables("樞紐分析表1" _
        ).PivotFields("數量"), "計數 - 數量", xlCount
    ActiveWorkbook.ShowPivotTableFieldList = False
    Columns("I:J").Select
    Selection.SpecialCells(xlCellTypeVisible).Select
    Selection.Copy
    Sheets("轉換").Select
    ActiveWindow.SmallScroll Down:=-9
    Range("A1").Select
    ActiveSheet.Paste
    Sheets("整理").Select
    Range("J4").Select

    Range("J4:J19864").Select
    Application.CutCopyMode = False
    With ActiveSheet.PivotTables("樞紐分析表1").PivotFields("計數 - 數量")
        .Caption = "加總 - 數量"
        .Function = xlSum
    End With

------------------------------------------------------------------------------------------------------------
80 字節以內
不支持自定義 Discuz! 代碼

回復 2# genes


    請問大大這該如何解決呢?
80 字節以內
不支持自定義 Discuz! 代碼

TOP

        靜思自在 : 愛不是要求對方,而是要由自身的付出。
返回列表 上一主題