cancel
Showing results for 
Search instead for 
Did you mean: 

Custom Validation in webdynpro or R/3 in ESS.

Former Member
0 Kudos

I Want to write Custom Validation for Street and House Number And Date Of Birth in Dependent & Benefiary Section of HR in ESS..Kindly suggest me where to write code in webdyn pro java or R/3.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hello,

I have added Validations from java side in isConsistent() method of component controller VcPerFamilyUsDetail & its working.

Regards

Deepa Kalyani.

Answers (7)

Answers (7)

Former Member
0 Kudos

Better to use onEvent, u will have more flexibility and control.

Former Member
0 Kudos

Thank you All...

Its working...

Former Member
0 Kudos

Pls close the thread and post ur solution so that it will be usefull for others.

Former Member
0 Kudos

Hi Deepa,

Validations u can try from badi. I would prefer badi instead of WDJ code change.

But in case if u had to make the WDJ code change then I think you have to write ur code in onEvent method. I think u may have to write it in OnEvent method of Detail screen component controller so that u can control and stop the navigation in case if validation fails.

I think in onEvent, u might have to check for EVENT_NEXT and then add ur code there.And if u have to prevent navigation from going to review screen then u have to return false.

Regards

Yugandhar Reddy

Former Member
0 Kudos

Hello,

I am new in ESS/Mss trying to find out the flow of program.

on Click of Review One Event is called in WDJ

fpm.raiseReviewAndSaveEvent(IFPM.EVENT_REVIEW, IFPM.EVENT_SAVE, thisVAC);

after that where the control going ,i am not able to trace that.

then in between some where one method of WDJ is executing below is the code

public boolean check( com.sap.tc.webdynpro.progmodel.api.IWDNodeElement selectedInfotypeElement )  {
    //@@begin check()
  try { 
   fpm.getMessageManager().deleteAllMessages(wdThis.wdGetAPI().getComponent());
   wdContext.nodeCheck().bind((Hrxss_Per_Check_Input) model.createModelObject(Hrxss_Per_Check_Input.class));
   wdContext.currentCheckElement().modelObject().execute();
   //@Begin
   for (int i = 0; i < wdContext.nodeCheckMessages().size(); i++)
   {
    ICheckMessagesElement messageElement = wdContext.nodeCheckMessages().getCheckMessagesElementAt(i);  
    String l_strType = messageElement.getType();
    if(l_strType.equals("E")|| l_strType.equals("A")|| l_strType.equals("X"))
    {
     open_confirmation_dialog(messageElement.getMessage(), 0, 0);
     break;
    }
   }
   //@End
   return MessageHelper.reportMessage(fpm, wdThis.wdGetAPI(), wdContext.nodeCheckMessages(), selectedInfotypeElement);
  } catch (Exception ex) {
   fpm.getMessageManager().raiseException(wdThis.wdGetAPI().getComponent(), ex);
   return false;
  }

    //@@end
  }

I have included custom validation for DOB in HRXSS_PER_MODIFY_P0021_**.Kindly Help.

Message was edited by: Deepa Kalyani

siddharthrajora
Product and Topic Expert
Product and Topic Expert
0 Kudos

BADI HRPAD00INFTYUI or HRPAD00INFTYBL should be sufficient. http://scn.sap.com/thread/1774498 http://scn.sap.com/thread/1774361 http://scn.sap.com/thread/1096060 check in threads.

former_member182426
Active Contributor
0 Kudos

I have added validation in R/3. but it is not showing validation message on portal.do i have to do something from web dynpro java side?

In R/3, where you have implemented this validation . In user exit program ZXPADU02 ?

then it wont display in portal.

You have to implement the BADI HRPAD00INFTYUI or customize in WDJAVA app.for this validations in portal.

Former Member
0 Kudos

Thank you jwala and yugandhar.

I have added validation in R/3. but it is not showing validation message on portal.do i have to do something from web dynpro java side?

Thanks & regards

Deepa

Former Member
0 Kudos

Success messages might not show up try error or warning msgs. Did u put breakpoint and check if its stopping there. Let us know the code that u wrote.

Former Member
0 Kudos

U HAVE TO WRITE IN R3 ....

Former Member
0 Kudos

check for suitable badi or u can also try it in conversion class