} /* PaintErrorRetreivingCammeraLineData */ private void SaveImageInLogDirectory() { if (chartBuff != null) { DateTime d = DateTime.Now; string logFileDir = OSservices.AddSlash(PicesSipperVariables.SipperInterfaceLogDir()) + "CameraLines"; string logFileName = OSservices.AddSlash(logFileDir) + "CameraLine_" + d.ToString("yyyy-MM-dd_HHmmss") + ".jpg"; OSservices.CreateDirectory(logFileDir); chartBuff.Save(logFileName); } } /* SaveImageInLogDirectory */
public SipperDisk(bool _readDirFromLogFiles) { BlockStart(); readDirFromLogFiles = _readDirFromLogFiles; openedSipperFiles = new List <SipperDiskFile> (); OpenSipperDrive(); if (fs == null) { validSipperDrive = false; BlockEnd(); throw new Exception("No SIPPER drive mounted on this system."); } if (!_readDirFromLogFiles) { GetListOfSipperFiles(); } else { String logDirName = PicesSipperVariables.SipperInterfaceLogDir(); GetListOfSipperFilesFromLogFiles(logDirName); //GetListOfSipperFilesFromLogFiles ("D:\\TrainingApp\\SipperInterfaceDir\\LogFiles"); //GetListOfSipperFilesFromLogFiles ("C:\\Temp\\Temp22"); //GetListOfSipperFilesFromLogFiles ("C:\\Pices\\SipperInterfaceDir\\LogFiles"); } if ((sipperFiles != null) && (sipperFiles.Count > 0)) { origFirstFileControlBlock = this.sipperFiles[0]; } // We are going to keep the handle to the physical disk close. If we were to leave it open; // it could cause stability issues for the system. We will open it when ever we need to perform // an operation on it. CloseHandleToPhysicalDisk(); BlockEnd(); }