@Override public void onl oad() throws Exception { super.onLoad(); //获取表头融合管理器 KDTMergeManager mm = this.tblMain.getHeadMergeManager(); // 进行指定融合,下标从0开始 // mm.mergeBlock(开始行下标,开始列下标,结束行下标,结束列下标, KDTMergeManager.SPECIFY_MERGE); int costBusinessTypeIndex = this.tblMain.getRow(0).getCell("costBusinessTypeName").getRowIndex(); int buildingNameIndex = this.tblMain.getRow(0).getCell("buildingName").getRowIndex(); //合并成本业务类型与楼栋 mm.mergeBlock(0, costBusinessTypeIndex, 1, costBusinessTypeIndex, KDTMergeManager.SPECIFY_MERGE); mm.mergeBlock(0, buildingNameIndex, 1, buildingNameIndex, KDTMergeManager.SPECIFY_MERGE); }
其他合并单元格及更多模式参看官方文档 https://vip.kingdee.com/article/371317112423730432?productLineId=8&isKnowledge=2&lang=zh-CN
标签:KDTMergeManager,下标,mm,buildingNameIndex,mergeBlock,表头,table,EAS From: https://www.cnblogs.com/ketoli/p/18222320