private void save() { VitalSignsVo voVitalSign = form.getLocalContext().getVitalSign(); VSPainLadderVo voPain = new VSPainLadderVo(); //------------------------------------ if(form.cmbPain().getValue() == null ) { engine.showMessage("Pain Score is mandatory."); return; } //------------------------------------ voPain.setPain(form.cmbPain().getValue()); voVitalSign.setPain(voPain); String[] arrErrors = voVitalSign.validate(); if(arrErrors == null) { try { domain.modifyPain(voVitalSign); } catch (StaleObjectException e) { engine.showMessage(ims.configuration.gen.ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue()); refresh(); return; } } else { engine.showErrors("Validation Errors", arrErrors); return; } form.getGlobalContext().Core.setVitalSign(voVitalSign); form.setMode(FormMode.VIEW); listPain(); dateIntervalStatus(); }