您好!调研下先,调研编号为SJS-27864,之后会及时向您同步结论,请您耐心等候。请教下您使用的具体版本号。
在此之前,您可以参考如下代码在导入文件后对各sheet中的数据区域自适应行高:
- var designer = GC.Spread.Sheets.Designer.findControl('gc-designer-container')
- let spread;
- designer.bind(GC.Spread.Sheets.Designer.Events.FileLoaded, function(e, args) {
- console.log('file loaded, args: ', args);
- spread = designer.getWorkbook();
- for (var i = 0; i < spread.getSheetCount(); i++) {
- var curSheet = spread.getSheet(i);
- var usedRange = curSheet.getUsedRange(GC.Spread.Sheets.UsedRangeType.data);
- if (usedRange) {
- curSheet.suspendPaint();
- for (var j = usedRange.row; j < usedRange.row + usedRange.rowCount; j++) {
- curSheet.autoFitRow(j);
- }
- curSheet.resumePaint();
- }
- }
- });
复制代码 |