Ejemplo n.º 1
0
        }//reference to calling object

        public int lShowForm()
        {
            mView = new CCollectionView();
            int lStatus = mView.lShowForm();

            return(lStatus);
        }
Ejemplo n.º 2
0
        // Purpose:  This function creates a new View object and calls its ShowForm method.
        // Author:   N/A - Framework template function
        // Written:  N/A
        // Modification Log
        // 001       04/27/1999      JG2596      Added Error handler and SysLog stuff

        public int lShowView()
        {
            //initialize the error handler routine
            int result = ProFitData.PFT_FAILURE;

            try
            {
                //log entry into ShowView method
                ProFitData.gFRWKSVC.SysLog("CCollection::lShowView - Entry", LogLevel.logAudit2);

                //Procedure level variables
                int lStatus = 0;

                //Instantiate the View and set its Parent
                mView        = new CCollectionView();
                mView.Parent = this;

                lStatus = mView.lShowForm();

                if (lStatus != ProFitData.PFT_SUCCESS)
                {
                    //log the failure of the ShowForm call
                    ProFitData.gFRWKSVC.SysLog("CCollection::lShowView - mView.lShowForm failed", LogLevel.logDebug3);
                    ProFitData.gFRWKSVC.SysLog("CCollection::lShowView - lStatus:  " + lStatus.ToString(), LogLevel.logDebug3);

                    //set return value to status
                    result = lStatus;

                    //send control to error handler
                    return(result);
                }

                //log a normal termination
                ProFitData.gFRWKSVC.SysLog("CCollection::lShowView - Normal Termination", LogLevel.logAudit2);

                //return a normal termination state

                return(ProFitData.PFT_SUCCESS);
            }
            catch (System.Exception _exception_)
            {
                Cerner.Foundations.Logging.ExceptionReporting.ReportException(_exception_);

                //ensure the function returns error status
                if (result == ProFitData.PFT_SUCCESS)
                {
                    result = ProFitData.PFT_FAILURE;
                }

                //log abnormal termination
                ProFitData.gFRWKSVC.SysLog("CCollection::lShowView - Abnormal Termination", LogLevel.logAudit2);

                return(result);
            }
        }