Skip to content

Can't decide between Date and Number cells #110

Description

@2knu

How can I decide if its a Date cell or just a number cell?
I want to read different excel sheets, where I don't know which one is a date cell.

There is only a CellType Number and not a Date type. So I could try to read every number as Date, but than numbers will be read wrong for me, because they arent dates mostly.

So what I would expect is:

if (cell.getType() == CellType.Date)
{ cell.asDate(); }
else if(cell.getType() == CellType.Number)
{ cell.asNumber(); }
else 
{ cell.getText(); }

Would be nice when smt. like this will work :)

Originally posted by @2knu in #91 (comment)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions