Esempio n. 1
0
        /// <summary>
        /// Handles the Unload event of the Page control and gets rid of initiated objects on the
        /// page startup.
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">The <see cref="EventArgs"/> instance containing the event data.</param>
        protected void Page_Unload(object sender, EventArgs e)
        {
            if (this.mUnitOfWorkObject != null)
            {
                this.mUnitOfWorkObject.Dispose();
                this.mUnitOfWorkObject = null;
            }

            if (this.mTopicBoObject != null)
            {
                this.mTopicBoObject = null;
            }

            if (this.mTopicHistoryBoObject != null)
            {
                this.mTopicHistoryBoObject = null;
            }
        }
Esempio n. 2
0
        /// <summary>
        /// Handles the Unload event of the Page control and gets rid of initiated objects on the
        /// page startup.
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">The <see cref="EventArgs"/> instance containing the event data.</param>
        protected void Page_Unload(object sender, EventArgs e)
        {
            if (this.mUnitOfWorkObject != null)
            {
                this.mUnitOfWorkObject.Dispose();
                this.mUnitOfWorkObject = null;
            }

            if (this.mTopicBoObject != null)
            {
                this.mTopicBoObject = null;
            }

            if (this.mTopicHistoryBoObject != null)
            {
                this.mTopicHistoryBoObject = null;
            }
        }