03-11-2010 2:41 PM
Hi everyone,
I am trying to learn Web Dynpro, can you please give me a good example of how to create a Web Dynpro application using a BAPI. let's say a BAPI to display the customer records, for example the user should be able to enter the customer number and get his details.
Any help will be appreciated.
Thanks,
Rajat
03-11-2010 2:54 PM
03-11-2010 2:54 PM
03-11-2010 3:40 PM
Thanks for the reply Rich I followed the tutorial and created the web application and everything looked perfect except when I am entering the from and to City details and clicking on get flight details button I am not getting any result. Can you please help me in this.
Thanks,
Rajat
03-11-2010 3:45 PM
03-11-2010 3:49 PM
Thanks for the quick reply Rich... I just looked the table that we are using in the BAPI and found that there is noithing in there.
03-11-2010 4:27 PM
03-11-2010 6:03 PM
Thanks for the reply Rich, I created couple of more web applications !! one for displaying the vendor details, i.e. enter the vendor number and you will get the details, and this one is working fine. Now i tried to create an application for displaying the invoice header details by entering the document number using BAPI "BAPI_INCOMINGINVOICE_GETDETAIL". but when I test it i get the screen where i Need to enter the invoice number, as soon as I enter the Invoice numbr and hit enter I am getting following errors.
The following error text was processed in the system RS2 : Incorrect parameter with CALL FUNCTION.
The termination type was: RABAX_STATE
The ABAP call stack was:
Method: EXECUTE_BAPI_INCOMINGINVOICE_G of program /1BCWDY/GZZAZ6OOVDTOY53TTZ5Y==CP
Method: IF_COMPONENTCONTROLLER~EXECUTE_BAPI_INCOMINGINVOICE_G of program /1BCWDY/GZZAZ6OOVDTOY53TTZ5Y==CP
Method: ONACTIONGET_INVOICE_DETAILS of program /1BCWDY/GZZAZ6OOVDTOY53TTZ5Y==CP
Method: IF_WDR_VIEW_DELEGATE~WD_INVOKE_EVENT_HANDLER of program /1BCWDY/GZZAZ6OOVDTOY53TTZ5Y==CP
Method: INVOKE_EVENTHANDLER of program CL_WDR_DELEGATING_VIEW========CP
Method: IF_WDR_ACTION~FIRE of program CL_WDR_ACTION=================CP
Method: DO_HANDLE_ACTION_EVENT of program CL_WDR_WINDOW_PHASE_MODEL=====CP
Method: PROCESS_REQUEST of program CL_WDR_WINDOW_PHASE_MODEL=====CP
Method: PROCESS_REQUEST of program CL_WDR_WINDOW=================CP
Method: EXECUTE of program CL_WDR_MAIN_TASK==============CP
Can you please help me with this.
03-11-2010 6:44 PM
03-11-2010 6:46 PM
Hi Rich,
I already did it and I found that I have commented Return parameter while calling the BAPI, Ijust uncommented that and I am getting this error now "RETURN" is not an internal table. I am looking into this.
Thanks,
Raj
03-11-2010 7:24 PM
Hi Rich,
I uncommented the retrun parameter but now I am getting this error:
"RETURN" is not an internal table "OCCURS n" specification is missing.
In the attributes I have declared this Attribute as:
Return with associated type BAPIRET2.
can you please see what am I doing wrong.
03-11-2010 7:54 PM
03-11-2010 8:07 PM
Hi Rich,
I have already tried doing this and I m still gettig the same message:
That's how my code looks like:
DATA: return type table of BAPIRET2.
CALL FUNCTION 'BAPI_INCOMINGINVOICE_GETDETAIL'
EXPORTING
INVOICEDOCNUMBER = LV_INVOICEDOCNUMBER
FISCALYEAR = LV_FISCALYEAR
IMPORTING
HEADERDATA = LS_C_HEADERDATA
ADDRESSDATA = LS_C_ADDRESSDATA
TABLES
ITEMDATA = LT_C_ITEMDATA
" accountingdata =
" glaccountdata =
" materialdata =
" taxdata =
" withtaxdata =
" vendoritemsplitdata =
RETURN = WD_THIS->RETURN
" extensionout =
and when I double clicked on the "RETURN" its taking me to the attribute section, where Attribute "Return" has been declared as Ref to BAPIRET2
03-11-2010 8:12 PM
Yes, try it without the WD_THIS reference, and add a period at the end of it.
DATA: return type table of BAPIRET2.
CALL FUNCTION 'BAPI_INCOMINGINVOICE_GETDETAIL'
EXPORTING
INVOICEDOCNUMBER = LV_INVOICEDOCNUMBER
FISCALYEAR = LV_FISCALYEAR
IMPORTING
HEADERDATA = LS_C_HEADERDATA
ADDRESSDATA = LS_C_ADDRESSDATA
TABLES
ITEMDATA = LT_C_ITEMDATA
" accountingdata =
" glaccountdata =
" materialdata =
" taxdata =
" withtaxdata =
" vendoritemsplitdata =
RETURN = RETURN. "<--- just use RETURN here, and add a period
" extensionout =
Regards,
Rich Heilman
03-11-2010 8:13 PM
Hi Rich,
Before you answered I changed my code.... and put return there but thanks a lot for your help !!!
03-11-2010 8:26 PM