on 04-17-2008 3:03 PM
Hi Guru's,
I'm using the BAPI, BAPI_GOODSMVT_GETITEMS to get the list of Materials in WEB Dynpro.
for this i 'm passing the following parameters.
Material ,Plant , Movement Type and Special Stock parameters.
When i passed the same parameters in the R/3 Server, i'm getting the data. In webdynpro i'm not getting the data.
Please give me the solution
Here is the code i've written in the view level to pass parameters.
Bapi_Goodsmvt_Getitems_Input input = new Bapi_Goodsmvt_Getitems_Input();
wdContext.nodeBapi_Goodsmvt_Getitems_Input().bind(input);
Bapi2017_Gm_Material_Ra input1 = new Bapi2017_Gm_Material_Ra();
wdContext.nodeBapi2017_Gm_Material_Ra().bind(input1);
Bapi2017_Gm_Move_Type_Ra input2 = new Bapi2017_Gm_Move_Type_Ra();
wdContext.nodeBapi2017_Gm_Move_Type_Ra().bind(input2);
Bapi2017_Gm_Plant_Ra input3 = new Bapi2017_Gm_Plant_Ra();
wdContext.nodeBapi2017_Gm_Plant_Ra().bind(input3);
Bapi2017_Gm_Spec_Stock_Ra input4 = new Bapi2017_Gm_Spec_Stock_Ra();
wdContext.nodeBapi2017_Gm_Spec_Stock_Ra().bind(input4);
wdContext.nodeBapi2017_Gm_Material_Ra().currentBapi2017_Gm_Material_RaElement().setSign("I");
wdContext.nodeBapi2017_Gm_Material_Ra().currentBapi2017_Gm_Material_RaElement().setOption("EQ");
wdContext.nodeBapi2017_Gm_Material_Ra().currentBapi2017_Gm_Material_RaElement().setLow("1857");
wdContext.nodeBapi2017_Gm_Plant_Ra().currentBapi2017_Gm_Plant_RaElement().setSign("I");
wdContext.nodeBapi2017_Gm_Plant_Ra().currentBapi2017_Gm_Plant_RaElement().setOption("EQ");
wdContext.nodeBapi2017_Gm_Plant_Ra().currentBapi2017_Gm_Plant_RaElement().setLow("M110");
wdContext.nodeBapi2017_Gm_Move_Type_Ra().currentBapi2017_Gm_Move_Type_RaElement().setSign("I");
wdContext.nodeBapi2017_Gm_Move_Type_Ra().currentBapi2017_Gm_Move_Type_RaElement().setOption("EQ");
wdContext.nodeBapi2017_Gm_Move_Type_Ra().currentBapi2017_Gm_Move_Type_RaElement().setLow("309");
wdContext.nodeBapi2017_Gm_Spec_Stock_Ra().currentBapi2017_Gm_Spec_Stock_RaElement().setSign("I");
wdContext.nodeBapi2017_Gm_Spec_Stock_Ra().currentBapi2017_Gm_Spec_Stock_RaElement().setOption("EQ");
wdContext.nodeBapi2017_Gm_Spec_Stock_Ra().currentBapi2017_Gm_Spec_Stock_RaElement().setLow("W");
//
wdThis.wdGetWdsdgoodsmvmtcustController().execute_BAPI_GOODSMOVEMENT_GETITEMS();
Please correct me if i'm wrong in coding.
Thanks & Regards,
Adi
This message was moderated.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Adi,
can you just try binding this way,
wdContext.nodeBapi_Goodsmvt_Getitems_Input().bind(new Bapi_Goodsmvt_Getitems_Input());
might work!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi ,
You have done one mistake while setting the input parameters for BAPI..Do the following steps for setting input to BAPI
Bapi_Goodsmvt_Getitems_Input input = new Bapi_Goodsmvt_Getitems_Input();
wdContext.nodeBapi_Goodsmvt_Getitems_Input().bind(input);
Bapi2017_Gm_Material_Ra input1 = new Bapi2017_Gm_Material_Ra();
wdContext.nodeBapi2017_Gm_Material_Ra().bind(input1);
Bapi2017_Gm_Move_Type_Ra input2 = new Bapi2017_Gm_Move_Type_Ra();
wdContext.nodeBapi2017_Gm_Move_Type_Ra().bind(input2);
Bapi2017_Gm_Plant_Ra input3 = new Bapi2017_Gm_Plant_Ra();
wdContext.nodeBapi2017_Gm_Plant_Ra().bind(input3);
Bapi2017_Gm_Spec_Stock_Ra input4 = new Bapi2017_Gm_Spec_Stock_Ra();
wdContext.nodeBapi2017_Gm_Spec_Stock_Ra().bind(input4);
input1.setSign("I");
input1.setOption("EQ");
input1.setLow("1857");
input2.setSign("I");
input2.setOption("EQ");
input2.setLow("M110");
input3.setSign("I");
input3.setOption("EQ");
input3.setLow("309");
input4.setSign("I");
input4.setOption("EQ");
input4.setLow("W");
//
wdThis.wdGetWdsdgoodsmvmtcustController().execute_BAPI_GOODSMOVEMENT_GETITEMS();
Finally inavidate your output node like
wdContext.node<output node name>.invalidate();
also put your code inside try catch to display any exception if any
Regards,
Amit Bagati
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Try invalidating output node
Regards,
Gopal
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
10 | |
7 | |
6 | |
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.