Closed thales-assis closed 1 year ago
Running some debuggers, I was able to identify that it is possible to set a field to "text" and put HyperLink as an empty structure (default). However, when I try to save the file it corrupts and gets broken. I'm not use sheet.Close()
and the emails from the original file have the hyperlink.
buffer := bytes.NewBuffer(nil)
err := xlsxFile.Write(buffer)
if err != nil {
return nil, err
}
return buffer.Bytes(), nil
Trying to overwrite the hyperlinked email field to an unlinked one:
cell.SetString(email)
cell.Hyperlink = xlsx.Hyperlink{}
It works, but when it comes to returning bytes and converting to file, it's broken/corrupted. I'm using the .xlsx
extension.
Stale issue message
Hi guys! How are you?
I've a question, when I try to return the file xlsx.File (converting to
[]bytes
) and it contains the cell with a Hyperlink (email), the file breaks and it becomes impossible to open it.Is it possible to clear all kind of formatting, hyperlink or something like that just so I can return the file successfully?
Image:![Screen Shot 2021-07-26 at 18 58 21](https://user-images.githubusercontent.com/17066350/127064552-6a5bab54-f61d-4126-ad40-7fe309e9773c.png)