DicomObjects.NET Core Documentation
DicomObjects Namespace / DicomGlobal Class / CloseFilesAfterReading Property



In This Topic
    CloseFilesAfterReading Property (DicomGlobal)
    In This Topic
    Controls how pixel data is read from disk
    Syntax
    'Declaration
     
    
    Public Shared Property CloseFilesAfterReading As Boolean
    'Usage
     
    
    Dim value As Boolean
     
    DicomGlobal.CloseFilesAfterReading = value
     
    value = DicomGlobal.CloseFilesAfterReading
    public static bool CloseFilesAfterReading {get; set;}
    public:
    static property bool CloseFilesAfterReading {
       bool get();
       void set (    bool value);
    }
    Remarks

    If true, then all the pixel data is read from the disk at the time of reading the file, and the file is then closed. if false, then the file is kept open and pixel data is only read as and when required.

    The default setting is true which improves memory usage, but has the downside that the file is locked. If you wish to over-write files which have been opened, then set this value to true before reading the files.

    The default value is false

    This corresponds to the old "DisableMemoryMapping" registry setting.

    If required, this behaviour can be controlled on a file by file basis by using the CloseFilesAfterReading property of the ReadBehaviours class, combined with the appropriate override of DicomDataSet.Read

    Requirements

    Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

    See Also