Ejemplo n.º 1
0
        /// <summary>
        /// Rendering del documento checkedout
        /// </summary>
        private void RenderCheckedOutDocument()
        {
            byte[] content = null;

            if (CheckOutPage.SessionContent == null)
            {
                // Se il download del file non è stato fatto
                // contestualmente al CheckOut, viene reperito
                // il content del file dal server
                content = CheckInOutServices.GetCheckedOutFileDocument();
            }
            else
            {
                // Se il file è già stato scaricato contestualmente al checkout,
                // viene reperito il content del file dalla sessione
                content = CheckOutPage.SessionContent;

                CheckOutPage.SessionContent = null;
            }

            if (content != null)
            {
                Response.BinaryWrite(content);
                Response.End();
            }
        }