on 04-09-2009 3:23 AM
Dear Expert,
I have a requirement which is to edit the ess~cod for the employee communication. I have copy out the function group ZHRXSS_COD_INTERFACE. I created my own function module ZCOD_VALIDATE and attached to the function group. My funtion module are just returning an export parameter and a table without getting any import parameter.
I have create a ZCodModel (pointing to the ECC function group) and the model class is ZCod_Validate_Output. I have done all the reimporting of the model and context binding. My question is why i still not getting any value from the function module. I tested the fm in ecc and it works well.
I have added the following code in do init.
*************************************
ZCod_Validate_Input Input = new ZCod_Validate_Input();
wdContext.nodeZCod_Validate_Input().bind(Input);
try {
wdContext.currentZCod_Validate_InputElement().modelObject().execute();
wdContext.nodeCod_Validate_Output().invalidate();
} catch (Exception ex) {
fpm.getMessageManager().raiseException(wdThis.wdGetAPI ().getComponent(), ex);
}
************************
Anyone can tell me why i am not getting the parameter? Please help me.
Thanks.
Regards,
Bryan
Dear all...found out the solution. Need to refresh the project and repair it
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Bryan,
The code seems to be alright for me.
Try these two options, if you have not done already:
1.Try to print resutls after execution
wdComponentAPI.getMessageManager().reportSuccess(size of the table or value of the parameter);
2.Try to debug if the RFC is called using external debugging in ABAP
If the RFC is callled and showing values null or 0
Just check once more your binding.
Regards,
Siva
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Siva,
Thanks for your reply.
I got this error when i execute it? Anyway my function module does also return a table but i have yet to define a context to store it. I am just trying to get the value of the export parameter. If it success, then i can proceed to bind the table. However now, it seem getting an export parameter also giving me problems.
********************************************************************************************************************
java.lang.ArrayIndexOutOfBoundsException: -1
at com.sap.mw.jco.JCO$Record.getString(JCO.java:12798)
at com.sap.aii.proxy.framework.core.JcoBaseTypeData.getElementValueAsString(JcoBaseTypeData.java:669)
at com.sap.tc.webdynpro.modelimpl.dynamicrfc.DynamicRFCModelClass.getAttributeValueAsString(DynamicRFCModelClass.java:427)
at com.sap.xss.hr.cod.model1.Zhrxss_Cod_Validate_Output.getNameofposition(Zhrxss_Cod_Validate_Output.java:164)
at com.sap.xss.hr.cod.wdp.IPublicFcCodBusinessLogicComp$IZhrxss_Cod_Validate_OutputElement.wdGetObject(IPublicFcCodBusinessLogicComp.java:6601)
********************************************************************************************************************
Thanks.
Regards,
Bryan
Hi Bryan,
Generally we get this java.lang.ArrayIndexOutOfBoundsException: -1
exception, when we don't have records in the node(table) and we are trying to access the records.
So, this means you are not getting values after executing the RFC.
Try with external debugging. Put a breakpoint in RFC and try executing the WD application. You can check where exactly you are missing
Regards,
Siva
Hi Siva,
My basis is having problem to turn the debugging option on for the j2ee engine. Do you mean i put a debug poing in the following line?
"wdContext.currentZCod_Validate_InputElement().modelObject().execute();"
If this is a stadard rfc call? How will it have things missing?
Thanks.
Regards,
Bryan
User | Count |
---|---|
101 | |
13 | |
13 | |
11 | |
11 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.