/// <summary>
    /// Gets the certification details.
    /// </summary>
    /// <returns></returns>
    private BusinessEntities.RaveHRCollection GetEmployeeResume(int employeeID)
    {
        Rave.HR.BusinessLayer.Employee.EmployeeResume objEmployeeResumeBAL;
        BusinessEntities.EmployeeResume objEmployeeResume;

        // Initialise Collection class object
        BusinessEntities.RaveHRCollection raveHRCollection = new BusinessEntities.RaveHRCollection();

        try
        {
            objEmployeeResumeBAL = new Rave.HR.BusinessLayer.Employee.EmployeeResume();
            objEmployeeResume    = new BusinessEntities.EmployeeResume();

            //objCertificationDetails.EMPId = 14;
            objEmployeeResume.EMPId = employeeID;

            raveHRCollection = objEmployeeResumeBAL.GetEmployeeResumeDetails(objEmployeeResume);
        }
        catch (RaveHRException ex)
        {
            LogErrorMessage(ex);
        }
        catch (Exception ex)
        {
            RaveHRException objEx = new RaveHRException(ex.Message, ex, Sources.PresentationLayer, CLASS_NAME, "GetEmployeeResumeDetails", EventIDConstants.RAVE_HR_EMPLOYEE_PRESENTATION_LAYER);
            LogErrorMessage(objEx);
        }

        return(raveHRCollection);
    }
    //19645-Ambar-Start
    protected void gvEmployeeResume_RowDeleting(object sender, GridViewDeleteEventArgs e)
    {
        Rave.HR.BusinessLayer.Employee.EmployeeResume objEmployeeDeleteResumeBAL;
        objEmployeeDeleteResumeBAL = new Rave.HR.BusinessLayer.Employee.EmployeeResume();

        objEmployeeDeleteResumeBAL.DeleteEmployeeResumeDetails(str_deletedfile, employee.EMPId);
        this.PopulateGrid(employee.EMPId);
    }
    /// <summary>
    /// Handles the Click event of the btnUpload control.
    /// </summary>
    /// <param name="sender">The source of the event.</param>
    /// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param>
    protected void btnUpload_Click(object sender, EventArgs e)
    {
        int    i;
        string fileExtension = System.IO.Path.GetExtension(fileResume.FileName).ToLower();

        if (ValidateControls())
        {
            char[] SPILITER_DOT = { '.' };
            Rave.HR.BusinessLayer.Employee.EmployeeResume objEmployeeResumeBAL;
            BusinessEntities.EmployeeResume objEmployeeResume = new BusinessEntities.EmployeeResume();
            objEmployeeResumeBAL = new Rave.HR.BusinessLayer.Employee.EmployeeResume();
            //string[] EmployeeArray = Convert.ToString(employee.EmailId.Replace("@rave-tech.com", "")).Split(SPILITER_DOT);

            objEmployeeResume.EMPId = employee.EMPId;
            string docName = "";

            //Googleconfigurable
            AuthorizationManager obj = new AuthorizationManager();
            docName = obj.GetUsernameBasedOnEmail(employee.EmailId);

            //if (employee.EmailId.ToLower().Trim().Contains("@rave-tech.com"))
            //{
            //    docName = employee.EmailId.ToLower().Replace("@rave-tech.com", "");
            //}
            //else
            //{
            //    docName = employee.EmailId.ToLower().Replace("@" + AuthorizationManagerConstants.NORTHGATEDOMAINEMAIL, "");
            //}
            objEmployeeResume.DocumentName = docName;

            //objEmployeeResume.DocumentName = employee.EmailId.Replace("@rave-tech.com", "");
            //GoogleMail
            //Googleconfigurable
            objEmployeeResume.ModifyDate = DateTime.Now;
            objEmployeeResume.ModifyBy   = obj.GetUsernameBasedOnEmail(UserRaveDomainId);
            //if (UserRaveDomainId != null && UserRaveDomainId.Contains("@rave-tech.co.in"))
            //{
            //    objEmployeeResume.ModifyBy = UserRaveDomainId.Replace("@rave-tech.co.in", "");
            //}
            //else if (UserRaveDomainId != null && UserRaveDomainId.ToLower().Contains("@" + AuthorizationManagerConstants.NORTHGATEDOMAIN))
            //{
            //    objEmployeeResume.ModifyBy = UserRaveDomainId.ToLower().Replace("@" + AuthorizationManagerConstants.NORTHGATEDOMAIN, "");
            //}

            objEmployeeResume.FileExtension = fileExtension;

            if (EmployeeResumeCollection == null)
            {
                EmployeeResumeCollection = new BusinessEntities.RaveHRCollection();
            }

            EmployeeResumeCollection.Add(objEmployeeResume);

            EmployeeResumeCollection = objEmployeeResumeBAL.AddEmployeeResumeDetails(objEmployeeResume);

            i = Convert.ToInt32(((BusinessEntities.EmployeeResume)(EmployeeResumeCollection.Item(0))).ResumeCount);

            if (gvEmployeeResume.Rows.Count > 1)
            {
                string OldDocumentName = ((System.Web.UI.WebControls.LinkButton)(gvEmployeeResume.Rows[1].FindControl("_lnkResume"))).Text;
                HfOldDocumentName.Value = OldDocumentName;
            }
            this.PopulateGrid(objEmployeeResume.EMPId);

            switch (i)
            {
            case 0:
                Upload(0, objEmployeeResume);
                break;

            case 1:
                Upload(1, objEmployeeResume);
                break;

            case 2:
                Upload(2, objEmployeeResume);
                break;
            }

            lblMessage.Text = "Employee Resume Uploaded successfully.";

            //Aarohi : Issue 30053(CR) : 22/12/2011 : Start
            //Send mail for Employee Resume Upload.
            Rave.HR.BusinessLayer.Employee.Employee employeeBL = new Rave.HR.BusinessLayer.Employee.Employee();
            employeeBL.SendUploadResumeMails(employee);
            //Aarohi : Issue 30053(CR) : 22/12/2011 : End
        }
    }