Skip to Content
0
Oct 27, 2005 at 10:26 PM

First Dynpro which accesses backend R3 system

21 Views

Hi,

I'm trying to write my first dynpro application which accesses backend r/3 data using bapi. Bapi ZDVZGOR_POR displays the TCURR table content. Its properties as follow:

Import:

P_TARIH

Tables:

I_CURX (FCURR, TCURR, FKURS, TKURS)

For this purpose I've created a dynpro application named DovizKurlari

I've created a view named DovizKurlariView

Imported Adaptive RFC Model as ZDVZGOR_POR.

I'm trying to write this sample by taking http://help.sap.com/saphelp_erp2004/helpdata/en/91/9c2226df76f64fa7783dcaa4534395/frameset.htm

tutorial as template.

My application will display only the table content, there will be no search function at the moment.

What I've done;

- Created application(DovizKurlari), view(DovizKurlariView), window(DovizKurlariWindow)

- Imported RFC Model ZDVZGOR_POR

- Added this model to Used Model

- Created a context model node under component controller with name Zdvzgor_Por_Input

- Added Zdvzgor_Por_Input->Output->I_Curx via Edit Model Binding

- Created a method for component controller with name executeZDVZGOR_POR and type void

- Added the following code for component controller

public void wdDoInit()

{

//@@begin wdDoInit()

Zdvzgor_Por_Input input = new Zdvzgor_Por_Input();

wdContext.nodeZdvzgor_Por_Input().bind(input);

//@@end

}

public void executeZDVZGOR_POR( )

{

//@@begin executeZDVZGOR_POR()

try {

// Calls remote function module BAPI_FLIGHT_GETLIST

wdContext.currentZdvzgor_Por_InputElement().modelObject().execute();

// Synchronise the data in the context with the data in the model

wdContext.nodeOutput().invalidate();

} catch (Exception ex) {

// If an exception is thrown, then the stack trace will be printed

ex.printStackTrace();

}

//@@end

}

- After I've added DovizKurlariComp to properties of view DovizKurlariView

- Created a table element under layout tab with name DovizKurlari

- Under context tab of view, I've added Zdvzgor_Por_Input model node and Zdvzgor_Por_Input->Output->I_Curx via Edit Model Binding option.

- I've edited the properties of table DovizKurlari with option "Create Binding" and added Output->I_Curx columns.

After those, I've deployed the application and run it but it displays only coulmn names at top, data is not displayed.

BAPI uses input value P_TARIH with default value (todays date).

<b>What I'm missing?</b>

regards