protected bool LoadPNSpec() { try { if (Algorithm.FindDataInDataTable(specParameters, SpecTableStructArray, Convert.ToString(GlobalParameters.CurrentChannel)) == null) { return(false); } losAMax = Convert.ToDouble(SpecTableStructArray[(byte)AdjustLosSpecs.LOSA].MaxValue); losDMin = Convert.ToDouble(SpecTableStructArray[(byte)AdjustLosSpecs.LOSD].MinValue); return(true); } catch (InnoExCeption ex)//from driver { //Log.SaveLogToTxt(ex.ID + ": " + ex.Message + "\r\n" + ex.StackTrace); exceptionList.Add(ex); return(false); } catch (Exception error)//from itself { //one way: deal this exception itself InnoExCeption ex = new InnoExCeption(ExceptionDictionary.Code._0x02000, error.StackTrace); //Log.SaveLogToTxt(ex.ID + ": " + ex.Message + "\r\n" + ex.StackTrace); exceptionList.Add(ex); return(false); //the other way is: should throw exception, rather than the above three code. see below: //throw new InnoExCeption(ExceptionDictionary.Code._0x02000, error.StackTrace); } }