Hi,

I have to perform validations on field before submitting the request
using SubmitAction button.

I have a fields called *FirstName (Text Box)* and *GroupsToBeRemoved
(List Box)*. If he did not select any value from the list box, the
SubmitAction button does not allow him to submit the request. For this,
i wrote a code in FristName (Text Box) in the following manner.

WINDOW.CHECKSELECTEDGRP = FUNCTION (INVOCATION) {
IF(USERDN.LENGTH > 0 ) {
VAR TEXTCNT1, TEXTCNT2;
TEXTCNT1 = FORM.GETVALUE(\"TMPSELAVAILACCESSTEXT\");
TEXTCNT2 = FORM.GETVALUE(\"TMPEXISTINGACCESSTEXT\");
IF((TEXTCNT1 != NULL && TEXTCNT2 == NULL) || (TEXTCNT1 == NULL &&
TEXTCNT2 != NULL) || (TEXTCNT1 != NULL && TEXTCNT2 != NULL)) {
*VAR RESULT = INVOCATION.PROCEED();
return result;
}
else if (textCNT1 == null && textCNT2 == null ){
form.showError("Select atleast one group from the Available Group
Access or Existing Group Access");
}
}
}
form.interceptAction("SubmitAction", "before", checkSelectedGrp);
*
If i enable the code, request is not at all sumitting the request. It
is strucking at *var result = invocation.proceed();* this line. If
comment the code then it is submitting the request.

Can anyone help me in this case.

Best Regards,
Krishna B


--
krishnabkr
------------------------------------------------------------------------
krishnabkr's Profile: http://forums.novell.com/member.php?userid=73532
View this thread: http://forums.novell.com/showthread.php?t=399924