Zetbox.Client.WPF.View.DocumentManagement.COMStream.Dispose C# (CSharp) Method

Dispose() public method

public Dispose ( ) : void
return void
        public void Dispose()
        {
            if (this._stream != null)
            {
                this._stream.Close();
                this._stream.Dispose();
                this._stream = null;
            }
        }

Usage Example

Example #1
0
        private void Release()
        {
            if (pHandler != null)
            {
                try
                {
                    pHandler.Unload();
                }
                catch { }
                Marshal.FinalReleaseComObject(pHandler);
                pHandler = null;
            }

            if (stream != null)
            {
                stream.Dispose();
                stream = null;
            }
        }