Piotr Czajkowski 2 hafta önce
ebeveyn
işleme
34fef552c5
1 değiştirilmiş dosya ile 5 ekleme ve 2 silme
  1. 5 2
      ExcelORM/ExcelORM/TypeExtensions.cs

+ 5 - 2
ExcelORM/ExcelORM/TypeExtensions.cs

@@ -132,7 +132,10 @@ public static class TypeExtensions
     {
         if (cell == null) return string.Empty;
 
-        var value = cell.GetString();
-        return cell.Style.IncludeQuotePrefix ? $"'{value}" : value;
+        var text = cell.GetString();
+        if (!cell.Value.IsText) return text;
+        if (text.Length == 0) return string.Empty;
+        
+        return cell.Style.IncludeQuotePrefix ? $"'{text}" : text;
     }
 }