소스 검색

reclassify button add sample check function

CXS 3 년 전
부모
커밋
77e4695529
2개의 변경된 파일8개의 추가작업 그리고 2개의 파일을 삭제
  1. 4 1
      OTSIncAMeasureApp/0-OTSModel/Measure/ParamData/COTSMsrPrjResultData.cs
  2. 4 1
      OTSIncAMeasureApp/ServiceCenter/FileHelper.cs

+ 4 - 1
OTSIncAMeasureApp/0-OTSModel/Measure/ParamData/COTSMsrPrjResultData.cs

@@ -1425,7 +1425,10 @@ namespace OTSModelSharp
         public bool Reclassify()
         {
             string strFilePath = FileHelper.GetFolderName(m_strPathName);
-
+            if(strFilePath==null)
+            {
+                return false;
+            }
 
             foreach (var spl in m_listSamples)
             {

+ 4 - 1
OTSIncAMeasureApp/ServiceCenter/FileHelper.cs

@@ -11,7 +11,10 @@ namespace OTSModelSharp.ServiceInterface
     {
         public static string GetFolderName(string a_strPathName)
         {
-
+            if (a_strPathName == "Untitled")
+            {
+                return null;
+            }
             string folderName = a_strPathName.Substring(0, a_strPathName.LastIndexOf("\\"));
             //DirectoryInfo d = new DirectoryInfo(a_strPathName);
             //return d.FullName;