cancel
Showing results for 
Search instead for 
Did you mean: 

Create Order BAPI

pbechani
Participant
0 Kudos

Hi.

I am new to Web Dynpro Programming. I want to create an order screen that will show only the following fields : order type,priority,equipment from the transaction code IW31.

I believe the BAPI is BAPI_ALM_ORDER_MAINTAIN. I have created a model where I have imported it as an adaptive RFC. I have created also the context for my custom controller, but When it comes to editing model binding I can't make out the fields to choose.

Help

Thankyou in advance

Accepted Solutions (1)

Accepted Solutions (1)

pbechani
Participant
0 Kudos

Hi.

Thank you very much. I have created the models and the controller and have also created binding to the controlls. The fields I am using are coming from it_Component,it_Header,it_Methods. I have made the following initialisation :

Bapi_Alm_Order_Maintain_Input input =

new Bapi_Alm_Order_Maintain_Input();

wdContext.nodeBapi_Alm_Order_Maintain_Input().bind(input);

When I run the application the fields are grayed out(disabled). How can Ienable this

former_member197348
Active Contributor
0 Kudos

Hai,

Find the parent node(structure) of fields that are disabled.

I'll give some example code. Let's say 'it_Component' belongs to <b>Bapiitcomp</b>.

Create an instance of that.

<i>Bapiitcomp comp = new Bapiitcomp();</i>

Find it's corresponding node of it.

and add it to input.

<i>input.addxxxxxx(comp);</i>

or <i> input.setxxxxxx(comp);</i>

Do the same for all fields same,the will get enabled.

If any doubts,just reply back.

Bye,

Siva

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi Prince,

You check the Cardinality of the folder.For the Input the cardinality of the value node should be 1..1 . You can change the cardinality and check it.

Kind regards

Mukesh

Former Member
0 Kudos

hi Prince,

You can try this.

1: Create new value node and value attributes in custom controler.

(eg)

Order as valuenode and order type,priority,equipment as attributes.

2: Bind the coressponding BAPI attribute using the data link.

3. Bind the Order node to Component Controler and check the required attributes .

I think this link will helpful to you

https://www.sdn.sap.com/irj/sdn/downloaditem?rid=/library/uuid/f0b0e990-0201-0010-cc96-d7ecd2e51715

https://www.sdn.sap.com/irj/sdn/downloaditem?rid=/library/uuid/5dcbe990-0201-0010-2c99-a2bc9e61acfc

https://www.sdn.sap.com/irj/sdn/downloaditem?rid=/library/uuid/20b6e990-0201-0010-5095-f3a465de5f30

Kind Regards,

Mukesh.

former_member197348
Active Contributor
0 Kudos

Hai Prince,

Use this method ,First delete the context nodes you have created. Open the data modelor diagram view, in left side choose arrow icon.Now link your controller to the model.A wizard appears, in that select *_input node drag it to left side controller's context. Next you can choose the nodes andattributes that you want.

All the best.

Bye,

siva

Former Member
0 Kudos

Hi Prince,

How are you editing the model binding between controller and model. You can right click on the controller's context and choose edit model binding or in the editor drag and drop(using delta link) the controller to model.

/Raj.