Skip to content

Nullable String in Version 4 #1

@Lure5134

Description

@Lure5134

I have a project where I use simplexcel and nullable strings. In the new version an exception gets thrown when the string is actual null.

Code to reproduce

string? nullableString = null;
Worksheet worksheet = new Worksheet("Example");
worksheet[0, 0] = nullableString;

The exception message

System.ArgumentException: The value must be a string for text cells. (Parameter 'value')
   at Simplexcel.Cell..ctor(CellType type, Object value, String format) in /_/src/Simplexcel/Cells/Cell.cs:line 33

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions