Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reading Numbers #49

Open
ghost opened this issue Oct 3, 2018 · 2 comments
Open

Reading Numbers #49

ghost opened this issue Oct 3, 2018 · 2 comments

Comments

@ghost
Copy link

ghost commented Oct 3, 2018

Hello,

I have a column with a formula to get numbers and i cannot retrieve those numbers:

package main

import (
	"fmt"

	"github.com/extrame/xls"
)

func main() {
	if xlFile, err := xls.Open("file.xls", "utf-8"); err == nil {
		if sheet := xlFile.GetSheet(0); sheet != nil {

			for i := 2; i <= (int(sheet.MaxRow)); i++ {
				row := sheet.Row(i)
				if row != nil {
					col := row.Col(3)
					fmt.Print("\n", col)
				}
			}
		}
	}

}

Everything else (text) i can retrieve

@ghost
Copy link
Author

ghost commented Oct 4, 2018

The column that i want to retrieve if has numbers i get "General", if the column has formulas i get nothing in the screen.

@sergeilem
Copy link
Contributor

sergeilem commented Mar 6, 2019

Problem with reading “general” instead of cell data is solved in my fork https://github.com/sergeilem/xls .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant