xuri
de38402f74
This closes #1031 , fix small float parsed error in some case
...
- new formula function: YEARFRAC, ref #65
- update the codecov version
- remove unused variable
3 years ago
xuri
490f3063c2
This closes #1026 , time parse accuracy issue and typo fixed
3 years ago
xuri
2add938798
- new formula functions: DATEVALUE, ref #65
...
- fix ineffectual variable assignments
- timeout in go test
3 years ago
xuri
dad8f490cc
This closes #417 and closes #520 , new API `GetCellType` has been added
3 years ago
xuri
32b23ef42d
This closes #998
...
- Support text comparison in the formula, also ref #65
- `GetCellValue`, `GetRows`, `GetCols`, `Rows` and `Cols` support to specify read cell with raw value, ref #621
- Add missing properties for the cell formula
- Update the unit test for the `CalcCellValue`
3 years ago
xuri
2616aa88cb
Add set shared formula support and documentation for the `SetCellFormula`
3 years ago
raochq
b02f864eab
This closes #844 , support get shared formula
3 years ago
three
f6f14f507e
Speed up merge cells
3 years ago
xuri
43a057b1ea
This closes #986 , fix set data validation drop list failed in some cases
...
Update documentation for `GetCellValue` and simplify code
3 years ago
xuri
c49e7aab30
Reduce cyclomatic complexities for the formula calculate function and update documentation for the API: `MergeCell` and `GetCellValue`
3 years ago
Arnie97
eaf9781e7e
Improve compatibility for SetRichText ( #976 )
...
- support escaped string literal
- maximum character limit added
- fix missing preserve character in some case
Co-authored-by: xuri <xuri.me@gmail.com>
4 years ago
xuri
e9ae9b45b2
change go module import path to github.com/xuri/excelize
4 years ago
xuri
90d200a10b
Make the functions `SetSheetRow`, `New Style` and `SetCellStyle` concurrency safety
4 years ago
xuri
544ef18a8c
- Support concurrency iterate rows and columns
...
- Rename exported field `File.XLSX` to `File.Pkg`
- Exported error message
4 years ago
xuri
2cfcf9eb5f
encode the escaped string literal which not permitted in an XML 1.0 document
4 years ago
xuri
be12cc27f1
This closes #652 , new SetColWidth API, support set column width in stream writing mode, and export error message
4 years ago
xuri
f8f699a172
Go 1.15 and later required, #65 fn: IMABS, IMCOS, IMCOSH, IMCOT, IMCSC, IMCSCH, IMEXP, IMLN and IMLOG10
4 years ago
xuri
2af96c0714
#65 fn: N, PERCENTILE.INC and T
...
typo fixed
4 years ago
James Allen
a12dfd3ce6
Add support for setting hyperlink display & tooltip ( closes #790 ) ( #794 )
4 years ago
xuri
5a0d885315
handle default underline type on get rich text; #65 fn: CODE, COLUMN, FIND, FINDB
4 years ago
xuri
d84050921e
check empty rich text run properties; new formula fn: LEFT, LEFTB, RIGHT, RIGHTB
4 years ago
tonnyzhang
bbb8ebfa8c
add GetCellRichText method and test ( #789 )
4 years ago
xuri
2833395347
This closes #787 , avoid duplicate rich text string items, new formula fn: BIN2DEC, BIN2HEX, BIN2OCT, HEX2BIN, HEX2DEC, HEX2OCT, OCT2BIN, OCT2DEC, OCT2HEX
4 years ago
xuri
9154d500cf
ref: #756 , set cell as blank when SetCellValue with nil #756 , new formula fn: BITAND, BITLSHIFT, BITOR, BITRSHIFT, BITXOR
4 years ago
xuri
a26675517e
This closes #756 , not set the empty string for the cell when SetCellValue with nil
4 years ago
Zhang Zhipeng
ad79505173
new formula func CLEAN and TRIM, change import path to v2 ( #747 )
4 years ago
Artem Kustikov
61057c58d3
Number format read fix ( #741 )
...
* fix UT-generated file names to be ignored
* fix cell value load with invalid number format ID
* fix PR issues
4 years ago
xuri
13e0ed2a69
Fixed #735 , refresh active tab after delete sheet
4 years ago
xuri
2514bb16c6
Fix #724 , standardize variable naming and update unit tests
4 years ago
xuri
4834a058aa
This closes #714 and closes #715 , fix wrong worksheet index returned by NewSheet in some case, fix panic on formatted value with no built-in number format ID
4 years ago
Artem Kustikov
f2b8798a34
extend cell value load to support custom datetime format ( #703 )
...
* extend cell value load to support custom datetime format
* cleanup incorrect imports
* fix numeric values conversion as done in legacy Excel
* fix tests coverage
* revert temporary package name fix
* remove personal info from test XLSX files
* remove unused dependencies
* update format conversion in parseTime
* new UT to increase code coverage
* Resolve code review issue for PR #703
* Rename broken file name generated by unit test
Co-authored-by: xuri <xuri.me@gmail.com>
4 years ago
xuri
88de2f8d51
Default row height compatibility with Apache OpenOffice and Kingsoft WPS, unit test update and typo fixed
4 years ago
xuri
c3e92a51d7
Compatible with Go 1.15, fix unit test failed on Windows and fixed #689 potential race condition
4 years ago
xuri
c922c32fb7
support parse and generate XML element namespace dynamic, fix #651
5 years ago
xuri
f7bd0729c6
Resolve #32 , fix missing leading/leading spaces when working with SST
5 years ago
xuri
15fd56853f
Update docs and typo fixed
5 years ago
xuri
5221729bc3
make columns iterator read cell streamingly and add max column limit on ColumnNumberToName
5 years ago
heiy
eb150c0c22
escape html tag
5 years ago
xuri
2ae631376b
add limits for total columns, row and filename length
5 years ago
xuri
c168233e70
speedup get cell value from shared string table
5 years ago
xuri
5c99300ee4
Fix #622 , storage string to SST (shared string table)
5 years ago
xuri
ec14de32f0
Merge branch 'master' into fix/cell_lock
5 years ago
xuri
882abb8098
- formula engine: reduce cyclomatic complexity
...
- styles: allow empty and default cell formats, #628
5 years ago
xuri
1fe660df64
- Resolve #485 use sheet index instead of ID
...
- added 3 internal function: getSheetID, getActiveSheetID, getSheetNameByID
5 years ago
xuri
e36650f4ff
Resolve #598 , filter support for AddPivotTable
5 years ago
xuri
66d0272f6a
Resolve #172 , init rich text support
5 years ago
xuri
09485b3f9f
Improve code coverage unit tests
5 years ago
Cameron Howey
5c87effc7e
Stream to Excel table ( #530 )
...
* Support all datatypes for StreamWriter
* Support setting styles with StreamWriter
**NOTE:** This is a breaking change. Values are now explicitly
passed as a []interface{} for simplicity. We also let styles to be
set at the same time.
* Create function to write stream into a table
* Write rows directly to buffer
Avoiding the xml.Encoder makes the streamer faster and use less
memory.
Using the included benchmark, the results went from:
> BenchmarkStreamWriter-4 514 2576155 ns/op 454918 B/op 6592 allocs/op
down to:
> BenchmarkStreamWriter-4 1614 777480 ns/op 147608 B/op 5570 allocs/op
* Use AddTable instead of SetTable
This requires reading the cells after they have been written,
which requires additional structure for the temp file.
As a bonus, we now efficiently allocate only one buffer when
reading the file back into memory, using the same approach
as ioutil.ReadFile.
* Use an exported Cell type to handle inline styles for StreamWriter
5 years ago
xuri
5f3a4bc39f
Fix #538 , added setting a major unit and tick label skip support for the chart
5 years ago
xuri
4e4a5b9b3e
Improve compatibility, fix workbook's rels ID calc error
5 years ago
xuri
da0d2ffbb6
Fix #533 , add support overlapped mergecells
5 years ago
马彦军
aa7eadbffe
fix go lock
5 years ago
xuri
2e791fa433
Optimize code of Getting/Setting Page Margins
5 years ago
heiy
810139f5fc
solve ending space missing
5 years ago
Christian Fiedler
3280e1b686
Allow access to more formula attributes in SetCellFormula ( #484 )
...
* Allow access to more formula attributes in SetCellFormula
Make SetCellFormula variadic to not break API.
The new arguments are option arguments in which the type of
the formula and the ref attribute may be set.
These need to be set for an array formula to work.
* Add TestWriteArrayFormula to test optional parameters of SetCellFormula
TestWriteArrayFormula writes a document to the test directory that
contains array formulas that are used to calculate standard deviations.
The file also contains values calculated by the Go testcase, so the
results can be verified. It should be tested, if the array formula
works (i.e. shows a number, not an error) and that the values calculated
by the formula and those calculated by Go are the same.
5 years ago
xuri
8922f65978
Combine functions:
...
workBookRelsWriter, drawingRelsWriter into relsWriter;
drawingRelsReader, workbookRelsReader, workSheetRelsReader into relsReader;
addDrawingRelationships, addSheetRelationships into addRels
5 years ago
mqy
64809db2c9
add missing error check in SetSheetRow()
5 years ago
Olivier Mengué
ac395a60ed
SetCellValue: use fmt.Sprint(v) instead of fmt.Sprintf("%v", v)
...
Because that does the same thing, but without having to parse a format
string.
Signed-off-by: Olivier Mengué <dolmen@cpan.org>
6 years ago
xuri
9c70d0ac86
Documentation updated, Go 1.10+ required
6 years ago
xuri
821632cf89
Fix #424 , refactor merged cells adjuster
6 years ago
xuri
b45c4b094c
Add a check for maximum limit hyperlinks in a worksheet
...
typo fixed
6 years ago
xuri
0660f30cdd
godoc update and typo fixed
6 years ago
xuri
a88459d5f1
add unit tests to functions
6 years ago
xuri
f2df344739
Resolve #369,#370
...
add error return value
exported functions:
GetMergeCells
ProtectSheet
UnprotectSheet
UpdateLinkedValue
GetMergeCells
SetSheetVisible
inner functions:
workSheetReader
copySheet
6 years ago
xuri
c423617e9d
Check max length for SetCellStr and fix coordinate issue for MergeCell
6 years ago
Aplulu
841ff4a03e
Fix out of range panic when removing formula.
...
Fix file corruption issue when deleting a sheet containing a formula.
6 years ago
xuri
40ff5dc1a7
refactor: handler error instead of panic,
...
Exported functions:
SetCellStyle
InsertCol
RemoveCol
RemoveRow
InsertRow
DuplicateRow
DuplicateRowTo
SetRowHeight
GetRowHeight
GetCellValue
GetCellFormula
GetCellHyperLink
SetCellHyperLink
SetCellInt
SetCellBool
SetCellFloat
SetCellStr
SetCellDefault
GetCellStyle
SetCellValue
MergeCell
SetSheetRow
SetRowVisible
GetRowVisible
SetRowOutlineLevel
GetRowOutlineLevel
GetRows
Columns
SearchSheet
AddTable
GetPicture
AutoFilter
GetColVisible
SetColVisible
GetColOutlineLevel
SetColOutlineLevel
SetColWidth
GetColWidth
inner functions:
adjustHelper
adjustMergeCells
adjustAutoFilter
prepareCell
setDefaultTimeStyle
timeToExcelTime
addDrawingChart
addDrawingVML
addDrawingPicture
getTotalRowsCols
checkRow
addDrawingShape
addTable
6 years ago
xuri
70b1a29165
Use bitSize for float32 type numbers conversion, relate PR #361
6 years ago
Michael
b2c12d784e
SetCellFloat for floats with specific precision ( #361 )
...
This allows the user to set a floating point value into a
cell with a specific number of places after the decimal.
Closes #357
6 years ago
Veniamin Albaev
dc01264562
Huge refactorig for consistent col/row numbering ( #356 )
...
* Huge refactorig for consistent col/row numbering
Started from simply changing ToALphaString()/TitleToNumber() logic and related fixes.
But have to go deeper, do fixes, after do related fixes and again and again.
Major improvements:
1. Tests made stronger again (But still be weak).
2. "Empty" returns for incorrect input replaces with panic.
3. Check for correct col/row/cell naming & addressing by default.
4. Removed huge amount of duplicated code.
5. Removed ToALphaString(), TitleToNumber() and it helpers functions at all,
and replaced with SplitCellName(), JoinCellName(), ColumnNameToNumber(), ColumnNumberToName(), CellNameToCoordinates(), CoordinatesToCellName().
6. Minor fixes for internal variable naming for code readability (ex. col, row for input params, colIdx, rowIdx for slice indexes etc).
* Formatting fixes
6 years ago
xuri
0072bb7310
resolve the issue corrupted xlsx after deleting formula of cell, reference #346
6 years ago
xuri
fabd9d013f
README updated
6 years ago
peiqi
ef334ee658
fix issue #290
6 years ago
xuri
3e004d900b
Comments style changed.
6 years ago
xuri
13a9769cc5
Comments style changed.
6 years ago
xuri
2f146c923c
Comments style changed.
6 years ago
xuri
b4a6e61ec3
Fix golint errors under confidence 0.1
6 years ago
xuri
ec37b114c3
Fixes #256 and format document.
7 years ago
xuri
aaced358f1
- Initialize shared formula types support, relate issue #227 ;
...
- go test and godoc has been updated
7 years ago
Ri Xu
564ebe48dd
- Fix `checkCellInArea()` index out of range when merged cell ref is single coordinate, relate issue #206 ;
...
- go test updated;
- Repository icon for SourceTree has been added
7 years ago
Ri Xu
770026e956
- New function `SetSheetRow()` has been added for support write whole line at once, relate issue #96 and #194 ;
...
- go test and godoc updated;
- Note that this function performance has not been tested
7 years ago
dvelderp
b25ec6e9d3
xlsx.SetCellValue() now supports bool value
7 years ago
mbresson
317ef65381
make SetCellStyle quicker by skipping conversions in checkCellInArea, and skipping area checks when we are sure the cell can't be before or past the current row/col
...
Signed-off-by: Matthieu Bresson
7 years ago
Ri Xu
52b1a8e896
- Function `SetCellValue()` time.Duration support added, relate issue #176 ;
...
- go test updated
7 years ago
Jinzhu
21214a514d
Rename import path to github.com/360EntSecGroup-Skylar/excelize
7 years ago
Ri Xu
f10ee929d0
- Bugfix: use sheet name in func `AddPicture`, relate issue #142 ;
...
- godoc updated
7 years ago
Ri Xu
b4ffa8ce48
- Add unsigned integer data type support, related issue #136 ;
...
- go test and godoc updated
Signed-off-by: Ri Xu <xuri.me@gmail.com>
7 years ago
Ri Xu
9b5b74d480
Performance optimization, use the array index instead of the value in range.
7 years ago
Ri Xu
905be463ed
Improve code readability.
7 years ago
Ri Xu
e820388d70
Handle coordinate parse exception, relate issue #122 .
7 years ago
Ri Xu
b7b937a8a3
godoc updated.
7 years ago
Ri Xu
f05f799f8d
- API changed, use worksheet name instead of "sheet" + index, related issue #25 , #43 , #47 , #51 , #89 , #101 , #116 and #120 .
...
- go test updated
7 years ago
Ri Xu
574a6b20d1
Golang 1.9 compatible, fix issue #111
7 years ago
Ri Xu
a8cf38ebd5
- New function `GetCellHyperLink()` added, relate issue #98 ;
...
- go test added
8 years ago
Takayuki Usui
88d10ff27b
Fix round-off error in representation of date and time values
8 years ago
Ri Xu
308776e350
Optimize code, go test and godoc updated.
8 years ago
Youngwan Kim
5a4870d1cf
Add extra argument "Linktype" to SetCellHyperLink
...
it support "External" and "Location"
Signed-off-by: Youngwan Kim <y103.kim@gmail.com>
8 years ago
Ri Xu
8493fea373
- Add number format code with unicode values, relate issue #86 ;
...
- godoc updated
8 years ago
Ri Xu
6aa59a1af2
- Init insert/remove column/row support. Relate issue #77 and #82 ;
...
- Readme and go test updated
8 years ago
Ri Xu
38df838598
Bugfix: unable to read the value of the merged cell, relate issue #78
8 years ago