Skip to Content
author's profile photo Former Member
Former Member

no data is displayd on the table

hi all,

i have 3 individual nodes of type structure.

now when i click a particilar button, the attributes of these nodes are taken and supplied to the bapi which den displays the result on the table.

Once when i read all the 3 individual nodes and then call the method as shown below but nothing gets displayd on the table....tried all possible solutions but no luck :[

data itab type standard table of BAPI_BCA_STR_CN_ACCT_EXT.

*

data wa type BAPI_BCA_STR_CN_ACCT_EXT.

*

*

*reading bank-country

DATA lo_nd_account_details TYPE REF TO if_wd_context_node.

DATA lo_el_account_details TYPE REF TO if_wd_context_element.

DATA ls_account_details TYPE wd_this->element_account_details.

DATA lv_bank_country LIKE ls_account_details-bank_country.

  • navigate from <CONTEXT> to <ACCOUNT_DETAILS> via lead selection

lo_nd_account_details = wd_context->get_child_node( name = wd_this->wdctx_account_details ).

  • get element via lead selection

lo_el_account_details = lo_nd_account_details->get_element( ).

  • get single attribute

lo_el_account_details->get_attribute(

EXPORTING

name = `BANK_COUNTRY`

IMPORTING

value = lv_bank_country ).

*reading bank-key

DATA lo_nd_account_details1 TYPE REF TO if_wd_context_node.

DATA lo_el_account_details1 TYPE REF TO if_wd_context_element.

DATA ls_account_details1 TYPE wd_this->element_account_details1.

DATA lv_bank_code LIKE ls_account_details1-bank_code.

  • navigate from <CONTEXT> to <ACCOUNT_DETAILS1> via lead selection

lo_nd_account_details1 = wd_context->get_child_node( name = wd_this->wdctx_account_details1 ).

  • get element via lead selection

lo_el_account_details1 = lo_nd_account_details1->get_element( ).

  • get single attribute

lo_el_account_details1->get_attribute(

EXPORTING

name = `BANK_CODE`

IMPORTING

value = lv_bank_code ).

*reading account-number

DATA lo_nd_account_details2 TYPE REF TO if_wd_context_node.

DATA lo_el_account_details2 TYPE REF TO if_wd_context_element.

DATA ls_account_details2 TYPE wd_this->element_account_details2.

DATA lv_account_number LIKE ls_account_details2-account_number.

  • navigate from <CONTEXT> to <ACCOUNT_DETAILS2> via lead selection

lo_nd_account_details2 = wd_context->get_child_node( name = wd_this->wdctx_account_details2 ).

  • get element via lead selection

lo_el_account_details2 = lo_nd_account_details2->get_element( ).

  • get single attribute

lo_el_account_details2->get_attribute(

EXPORTING

name = `ACCOUNT_NUMBER`

IMPORTING

value = lv_account_number ).

WA-BANK_COUNTRY = lv_bank_country.

WA-BANK_CODE = lv_bank_code.

WA-account_number = lv_account_number.

Append WA to ITAB.

IF SY-SUBRC <> 0.

COMMIT WORK.

ENDIF.

CALL FUNCTION 'BAPI_BCA_PAYMITEM_GET_LIST'

EXPORTING

ACCOUNTIDENT = wa.

*

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

5 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Jan 16, 2008 at 10:10 AM

    hi urbashi.....

    first place a breakpoint in the code and check whether the bapi returns any value.....

    then try executing the bapi from se37 providing the sameset of values and check for the results.

    ---regards,

    alex b justin

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 16, 2008 at 10:17 AM

    Hi Urbashi Dewan

    Check ur bapi 'BAPI_BCA_PAYMITEM_GET_LIST' in se 37 with ur values, if its returning some values there.. if its returning some values, then go debug the wda . try putting break point before the bapi call and check the parameters u are passing.

    Regards

    Sarath

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      On the click of your button, you need to know whether to make it visible or invisible.

      Let's say it's a toggle kind of thing - that is, if it is visible, it will become invisible and if it is invisible, it shall become visible on the click of the button.

      To achieve this:

      DATA lo_nd_group_vis TYPE REF TO if_wd_context_node.

      DATA lo_el_group_vis TYPE REF TO if_wd_context_element.

      DATA ls_group_vis TYPE wd_this->element_group_vis.

      DATA lv_visible2 LIKE ls_group_vis-visible2.

      navigate from <CONTEXT> to <GROUP_VIS> via lead selection

      lo_nd_group_vis = wd_context->get_child_node( name = wd_this->wdctx_group_vis ).

      get element via lead selection

      lo_el_group_vis = lo_nd_group_vis->get_element( ).

      get single attribute

      lo_el_group_vis->get_attribute(

      EXPORTING

      name = `VISIBLE2`

      IMPORTING

      value = lv_visible2 ).

      if lv_visible2 = abap_false.

      lv_visible2 = abap_true.

      else.

      lv_visible2 = abap_false.

      endif.

      lo_el_group_vis->set_attribute(

      EXPORTING

      name = `VISIBLE2`

      value = lv_visible2 ).

      Hope it helps...

  • Posted on Jan 16, 2008 at 10:17 AM

    Hi,

    Three possible cases may arise in your case:

    1) Check if the bapi is returnoing any data

    2) If you want to display the data in normal table , check if you have binded the data to the node and binded the node to the table.

    3) If you are using ALV map the node containing data to the node called DATA in the interface controller

    Regards,

    Madhu

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 17, 2008 at 08:57 AM

    HI

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 17, 2008 at 10:03 AM

    Thanks a lot

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.