} catch (ExistingServiceException e) {
} catch (DomainException e) {
    public ActionForward editGroupProperties(ActionMapping mapping, ActionForm form,            HttpServletRequest request, HttpServletResponse response) throws FenixActionException,            FenixFilterException {        HttpSession session = request.getSession(false);        DynaActionForm editGroupPropertiesForm = (DynaActionForm) form;        String groupPropertiesString = request.getParameter("groupPropertiesCode");        Integer groupPropertiesCode = new Integer(groupPropertiesString);        String name = (String) editGroupPropertiesForm.get("name");        String projectDescription = (String) editGroupPropertiesForm.get("projectDescription");        String maximumCapacityString = (String) editGroupPropertiesForm.get("maximumCapacity");        String minimumCapacityString = (String) editGroupPropertiesForm.get("minimumCapacity");        String idealCapacityString = (String) editGroupPropertiesForm.get("idealCapacity");        String groupMaximumNumber = (String) editGroupPropertiesForm.get("groupMaximumNumber");        String enrolmentBeginDayString = (String) editGroupPropertiesForm                .get("enrolmentBeginDayFormatted");        String enrolmentBeginHourString = (String) editGroupPropertiesForm                .get("enrolmentBeginHourFormatted");        String enrolmentEndDayString = (String) editGroupPropertiesForm.get("enrolmentEndDayFormatted");        String enrolmentEndHourString = (String) editGroupPropertiesForm                .get("enrolmentEndHourFormatted");        String shiftType = (String) editGroupPropertiesForm.get("shiftType");        String enrolmentPolicy = (String) editGroupPropertiesForm.get("enrolmentPolicy");        Calendar enrolmentBeginDay = null;        if (!enrolmentBeginDayString.equals("")) {            String[] beginDate = enrolmentBeginDayString.split("/");            enrolmentBeginDay = Calendar.getInstance();            enrolmentBeginDay.set(Calendar.DAY_OF_MONTH, (new Integer(beginDate[0])).intValue());            enrolmentBeginDay.set(Calendar.MONTH, (new Integer(beginDate[1])).intValue() - 1);            enrolmentBeginDay.set(Calendar.YEAR, (new Integer(beginDate[2])).intValue());            if (!enrolmentBeginHourString.equals("")) {                String[] beginHour = enrolmentBeginHourString.split(":");                enrolmentBeginDay.set(Calendar.HOUR_OF_DAY, (new Integer(beginHour[0])).intValue());                enrolmentBeginDay.set(Calendar.MINUTE, (new Integer(beginHour[1])).intValue());                enrolmentBeginDay.set(Calendar.SECOND, 0);            }        }        Calendar enrolmentEndDay = null;        if (!enrolmentEndDayString.equals("")) {            String[] endDate = enrolmentEndDayString.split("/");            enrolmentEndDay = Calendar.getInstance();            enrolmentEndDay.set(Calendar.DAY_OF_MONTH, (new Integer(endDate[0])).intValue());            enrolmentEndDay.set(Calendar.MONTH, (new Integer(endDate[1])).intValue() - 1);            enrolmentEndDay.set(Calendar.YEAR, (new Integer(endDate[2])).intValue());            if (!enrolmentEndHourString.equals("")) {                String[] endHour = enrolmentEndHourString.split(":");                enrolmentEndDay.set(Calendar.HOUR_OF_DAY, (new Integer(endHour[0])).intValue());                enrolmentEndDay.set(Calendar.MINUTE, (new Integer(endHour[1])).intValue());                enrolmentEndDay.set(Calendar.SECOND, 0);            }        }        IUserView userView = (IUserView) session.getAttribute(SessionConstants.U_VIEW);        InfoGrouping infoGroupProperties = new InfoGrouping();        infoGroupProperties.setIdInternal(groupPropertiesCode);        infoGroupProperties.setEnrolmentBeginDay(enrolmentBeginDay);        infoGroupProperties.setEnrolmentEndDay(enrolmentEndDay);        infoGroupProperties                .setEnrolmentPolicy(new EnrolmentGroupPolicyType(new Integer(enrolmentPolicy)));        if (!groupMaximumNumber.equals(""))            infoGroupProperties.setGroupMaximumNumber(new Integer(groupMaximumNumber));        Integer maximumCapacity = null;        Integer minimumCapacity = null;        Integer idealCapacity = null;        if (!maximumCapacityString.equals("")) {            maximumCapacity = new Integer(maximumCapacityString);            infoGroupProperties.setMaximumCapacity(maximumCapacity);        }        if (!minimumCapacityString.equals("")) {            minimumCapacity = new Integer(minimumCapacityString);            if (maximumCapacity != null)                if (minimumCapacity.compareTo(maximumCapacity) > 0) {                    ActionErrors actionErrors = new ActionErrors();                    ActionError error = null;                    error = new ActionError("error.groupProperties.minimum");                    actionErrors.add("error.groupProperties.minimum", error);                    saveErrors(request, actionErrors);                    return prepareEditGroupProperties(mapping, form, request, response);                }            infoGroupProperties.setMinimumCapacity(minimumCapacity);        }        if (!idealCapacityString.equals("")) {            idealCapacity = new Integer(idealCapacityString);            if (!minimumCapacityString.equals("")) {                if (idealCapacity.compareTo(minimumCapacity) < 0) {                    ActionErrors actionErrors = new ActionErrors();                    ActionError error = null;                    error = new ActionError("error.groupProperties.ideal.minimum");                    actionErrors.add("error.groupProperties.ideal.minimum", error);                    saveErrors(request, actionErrors);                    return prepareEditGroupProperties(mapping, form, request, response);                }            }            if (!maximumCapacityString.equals("")) {                if (idealCapacity.compareTo(maximumCapacity) > 0) {                    ActionErrors actionErrors = new ActionErrors();                    ActionError error = null;                    error = new ActionError("error.groupProperties.ideal.maximum");                    actionErrors.add("error.groupProperties.ideal.maximum", error);                    saveErrors(request, actionErrors);                    return prepareEditGroupProperties(mapping, form, request, response);                }            }            infoGroupProperties.setIdealCapacity(idealCapacity);        }        infoGroupProperties.setName(name);        infoGroupProperties.setProjectDescription(projectDescription);        if (!shiftType.equals("Sem Turno") && !shiftType.equals("SEM TURNO")) {            infoGroupProperties.setShiftType(ShiftType.valueOf(shiftType));        }        Integer objectCode = getObjectCode(request);        Object args[] = { objectCode, infoGroupProperties };        List errors = new ArrayList();        try {            errors = (List) ServiceManagerServiceFactory.executeService(userView, "EditGrouping",                    args);        } catch (InvalidSituationServiceException e) {            ActionErrors actionErrors = new ActionErrors();            ActionError error = null;            error = new ActionError("error.noGroupProperties");            actionErrors.add("error.noGroupProperties", error);            saveErrors(request, actionErrors);            return prepareViewExecutionCourseProjects(mapping, form, request, response);        } catch (ExistingServiceException e) {            ActionErrors actionErrors = new ActionErrors();            ActionError error = null;            error = new ActionError("error.exception.existing.groupProperties");            actionErrors.add("error.exception.existing.groupProperties", error);            saveErrors(request, actionErrors);            return prepareEditGroupProperties(mapping, form, request, response);        } catch (FenixServiceException e) {            throw new FenixActionException(e);        }        if (errors.size() != 0) {            ActionErrors actionErrors = new ActionErrors();            Iterator iterErrors = errors.iterator();            ActionError errorInt = null;            errorInt = new ActionError("error.exception.editGroupProperties");            actionErrors.add("error.exception.editGroupProperties", errorInt);            while (iterErrors.hasNext()) {                Integer intError = (Integer) iterErrors.next();                if (intError.equals(Integer.valueOf(-1))) {                    ActionError error = null;                    error = new ActionError("error.exception.nrOfGroups.editGroupProperties");                    actionErrors.add("error.exception.nrOfGroups.editGroupProperties", error);                }                if (intError.equals(Integer.valueOf(-2))) {                    ActionError error = null;                    error = new ActionError("error.exception.maximumCapacity.editGroupProperties");                    actionErrors.add("error.exception.maximumCapacity.editGroupProperties", error);                }                if (intError.equals(Integer.valueOf(-3))) {                    ActionError error = null;                    error = new ActionError("error.exception.minimumCapacity.editGroupProperties");                    actionErrors.add("error.exception.minimumCapacity.editGroupProperties", error);                }            }            saveErrors(request, actionErrors);        }        return prepareViewExecutionCourseProjects(mapping, form, request, response);    }