From 7b866816785ac1ca9787b63d4bff12873bb3a593 Mon Sep 17 00:00:00 2001 From: wmayer Date: Thu, 18 Oct 2018 23:32:32 +0200 Subject: [PATCH] fixes 0003638: Importing CSV-files produces an empty spreadsheet without the data --- src/Mod/Spreadsheet/App/Sheet.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/Mod/Spreadsheet/App/Sheet.cpp b/src/Mod/Spreadsheet/App/Sheet.cpp index 81afa4f962..44f455050c 100644 --- a/src/Mod/Spreadsheet/App/Sheet.cpp +++ b/src/Mod/Spreadsheet/App/Sheet.cpp @@ -143,15 +143,13 @@ void Sheet::clearAll() bool Sheet::importFromFile(const std::string &filename, char delimiter, char quoteChar, char escapeChar) { Base::FileInfo fi(filename); - Base::ifstream file(fi); + Base::ifstream file(fi, std::ios::in); int row = 0; PropertySheet::AtomicPropertyChange signaller(cells); clearAll(); - file.open(filename.c_str(), std::ios::in); - if (file.is_open()) { std::string line;