- var sheet = this.spread.sheets[3];
- var person = this.aa
- var typename = [
- 'oneyear.value.coalescing.accountsReceivable',
- 'oneyear.value.coalescing.prepayment',
- 'oneyear.value.coalescing.inventory',
- 'oneyear.value.coalescing.currentAssets',
- 'oneyear.value.coalescing.totalAssets',
- 'oneyear.value.coalescing.currentLiabilities',
- 'oneyear.value.coalescing.totalLiabilities',
- '',
- 'oneyear.value.coalescing.operatingIncome',
- 'oneyear.value.coalescing.operatingCosts',
- 'oneyear.value.coalescing.businessTax',
- 'oneyear.value.coalescing.interestExpense',
- 'oneyear.value.coalescing.theChangeOfIncomeFairValue',
- 'oneyear.value.coalescing.investmentIncome',
- 'oneyear.value.coalescing.totalProfit',
- 'oneyear.value.coalescing.netProfit',
- '',
- 'oneyear.value.coalescing.cashFlowFromOperations',
- 'oneyear.value.coalescing.investingCashFlows',
- 'oneyear.value.coalescing.cashFlowsFromFinancing',
- ]
- var typename2 = [
- 'twoyear.value.coalescing.accountsReceivable',
- 'twoyear.value.coalescing.prepayment',
- 'twoyear.value.coalescing.inventory',
- 'twoyear.value.coalescing.currentAssets',
- 'twoyear.value.coalescing.totalAssets',
- 'twoyear.value.coalescing.currentLiabilities',
- 'twoyear.value.coalescing.totalLiabilities',
- '',
- 'twoyear.value.coalescing.operatingIncome',
- 'twoyear.value.coalescing.operatingCosts',
- 'twoyear.value.coalescing.businessTax',
- 'twoyear.value.coalescing.interestExpense',
- 'twoyear.value.coalescing.theChangeOfIncomeFairValue',
- 'twoyear.value.coalescing.investmentIncome',
- 'twoyear.value.coalescing.totalProfit',
- 'twoyear.value.coalescing.netProfit',
- '',
- 'twoyear.value.coalescing.cashFlowFromOperations',
- 'twoyear.value.coalescing.investingCashFlows',
- 'twoyear.value.coalescing.cashFlowsFromFinancing',
- ]
- var typename3 = [
- 'threeyear.value.coalescing.accountsReceivable',
- 'threeyear.value.coalescing.prepayment',
- 'threeyear.value.coalescing.inventory',
- 'threeyear.value.coalescing.currentAssets',
- 'threeyear.value.coalescing.totalAssets',
- 'threeyear.value.coalescing.currentLiabilities',
- 'threeyear.value.coalescing.totalLiabilities',
- '',
- 'threeyear.value.coalescing.operatingIncome',
- 'threeyear.value.coalescing.operatingCosts',
- 'threeyear.value.coalescing.businessTax',
- 'threeyear.value.coalescing.interestExpense',
- 'threeyear.value.coalescing.theChangeOfIncomeFairValue',
- 'threeyear.value.coalescing.investmentIncome',
- 'threeyear.value.coalescing.totalProfit',
- 'threeyear.value.coalescing.netProfit',
- '',
- 'threeyear.value.coalescing.cashFlowFromOperations',
- 'threeyear.value.coalescing.investingCashFlows',
- 'threeyear.value.coalescing.cashFlowsFromFinancing',
- ]
- var typename4 = [
- 'oneyear.value.parentCompany.accountsReceivable',
- 'oneyear.value.parentCompany.prepayment',
- 'oneyear.value.parentCompany.inventory',
- 'oneyear.value.parentCompany.currentAssets',
- 'oneyear.value.parentCompany.totalAssets',
- 'oneyear.value.parentCompany.currentLiabilities',
- 'oneyear.value.parentCompany.totalLiabilities',
- '',
- 'oneyear.value.parentCompany.operatingIncome',
- 'oneyear.value.parentCompany.operatingCosts',
- 'oneyear.value.parentCompany.businessTax',
- 'oneyear.value.parentCompany.interestExpense',
- 'oneyear.value.parentCompany.theChangeOfIncomeFairValue',
- 'oneyear.value.parentCompany.investmentIncome',
- 'oneyear.value.parentCompany.totalProfit',
- 'oneyear.value.parentCompany.netProfit',
- '',
- 'oneyear.value.parentCompany.cashFlowFromOperations',
- 'oneyear.value.parentCompany.investingCashFlows',
- 'oneyear.value.parentCompany.cashFlowsFromFinancing',
- ]
- var typename5 = [
- 'twoyear.value.parentCompany.accountsReceivable',
- 'twoyear.value.parentCompany.prepayment',
- 'twoyear.value.parentCompany.inventory',
- 'twoyear.value.parentCompany.currentAssets',
- 'twoyear.value.parentCompany.totalAssets',
- 'twoyear.value.parentCompany.currentLiabilities',
- 'twoyear.value.parentCompany.totalLiabilities',
- '',
- 'twoyear.value.parentCompany.operatingIncome',
- 'twoyear.value.parentCompany.operatingCosts',
- 'twoyear.value.parentCompany.businessTax',
- 'twoyear.value.parentCompany.interestExpense',
- 'twoyear.value.parentCompany.theChangeOfIncomeFairValue',
- 'twoyear.value.parentCompany.investmentIncome',
- 'twoyear.value.parentCompany.totalProfit',
- 'twoyear.value.parentCompany.netProfit',
- '',
- 'twoyear.value.parentCompany.cashFlowFromOperations',
- 'twoyear.value.parentCompany.investingCashFlows',
- 'twoyear.value.parentCompany.cashFlowsFromFinancing',
- ]
- var typename6 = [
- 'threeyear.value.parentCompany.accountsReceivable',
- 'threeyear.value.parentCompany.prepayment',
- 'threeyear.value.parentCompany.inventory',
- 'threeyear.value.parentCompany.currentAssets',
- 'threeyear.value.parentCompany.totalAssets',
- 'threeyear.value.parentCompany.currentLiabilities',
- 'threeyear.value.parentCompany.totalLiabilities',
- '',
- 'threeyear.value.parentCompany.operatingIncome',
- 'threeyear.value.parentCompany.operatingCosts',
- 'threeyear.value.parentCompany.businessTax',
- 'threeyear.value.parentCompany.interestExpense',
- 'threeyear.value.parentCompany.theChangeOfIncomeFairValue',
- 'threeyear.value.parentCompany.investmentIncome',
- 'threeyear.value.parentCompany.totalProfit',
- 'threeyear.value.parentCompany.netProfit',
- '',
- 'threeyear.value.parentCompany.cashFlowFromOperations',
- 'threeyear.value.parentCompany.investingCashFlows',
- 'threeyear.value.parentCompany.cashFlowsFromFinancing',
- ]
- var source = new GC.Spread.Sheets.Bindings.CellBindingSource(person);
- sheet.setBindingPath(2, 2, 'oneyear.year');
- sheet.setBindingPath(2, 3, 'twoyear.year');
- sheet.setBindingPath(2, 4, 'threeyear.year');
- sheet.setBindingPath(30, 2, 'oneyear.year');
- sheet.setBindingPath(30, 3, 'twoyear.year');
- sheet.setBindingPath(30, 4, 'threeyear.year');
- sheet.setText(7, 7, '01/01/2014');
- var num = 3
- for (var i = 0; i < 20;i++){
- num++
- sheet.setBindingPath(num, 2, typename[i])
- sheet.setBindingPath(num, 3, typename2[i])
- sheet.setBindingPath(num, 4, typename3[i])
- }
- var num2 = 31
- for (var n = 0; n < 20; n++) {
- num2++
- sheet.setBindingPath(num2, 2, typename4[n])
- sheet.setBindingPath(num2, 3, typename5[n])
- sheet.setBindingPath(num2, 4, typename6[n])
- }
- sheet.setDataSource(source);
复制代码 这是插入代码的部分,setValue,setArray,getText输入数据都可以导出,但是setBindingPath 导出就是空的,全部都是空的,一个都没有
然后还有一个问题,有没有好的批量导入导出数据的方法,
|
|