From bcc0f472937145c696aa5fd38428fa914e9eaa1f Mon Sep 17 00:00:00 2001 From: kimsama Date: Wed, 27 Apr 2016 20:00:13 +0900 Subject: [PATCH] Modified to put more clear exception log. --- Assets/QuickSheet/ExcelPlugin/Editor/ExcelQuery.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Assets/QuickSheet/ExcelPlugin/Editor/ExcelQuery.cs b/Assets/QuickSheet/ExcelPlugin/Editor/ExcelQuery.cs index b0f4014..e182f50 100644 --- a/Assets/QuickSheet/ExcelPlugin/Editor/ExcelQuery.cs +++ b/Assets/QuickSheet/ExcelPlugin/Editor/ExcelQuery.cs @@ -24,6 +24,7 @@ public class ExcelQuery { private readonly IWorkbook workbook = null; private readonly ISheet sheet = null; + private string filepath = string.Empty; /// /// Constructor. @@ -32,6 +33,8 @@ public ExcelQuery(string path, string sheetName = "") { try { + this.filepath = path; + using (FileStream fileStream = new FileStream(path, FileMode.Open, FileAccess.Read, FileShare.ReadWrite)) { string extension = GetSuffix(path); @@ -161,7 +164,7 @@ public List Deserialize(int start = 1) catch(Exception e) { string pos = string.Format("Row[{0}], Cell[{1}]", (current + 1).ToString(), GetHeaderColumnName(i)); - Debug.LogError("Excel Deserialize Exception: " + e.Message + " " + pos); + Debug.LogError(string.Format("Excel File {0} Deserialize Exception: {1} at {2}", this.filepath, e.Message, pos)); } } }