xspreadsheet
xspreadsheet copied to clipboard
关于创建更多的列
从xspreadsheet/src/core/alphabet.ts里代码来看,貌似只能支持到26*27-1列,再多就有问题了,可以试试:
const _alphabet = ['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z']
function alphabet(index: number): string {
const [a, b] = [parseInt(index / _alphabet.length + ''), index % _alphabet.length]
return a > 0 ? `${ a > _alphabet.length ? alphabet(a-1) : _alphabet[a - 1]}${_alphabet[b]}` : _alphabet[b]
}
请关注最新项目: https://github.com/myliang/xspreadsheet
这个项目以后不再维护了,请关注新项目