Skip to Content
avatar image
Former Member

how to refresh table output?

hi experts,

i have three column in table .

one as textview with text,

second one as button and

third one is as textview as null.

What my case is: when user click on button ( second column ) , i get popup winow(with popup view having text editor ), user will write some text that will get copied to third column which is as textview.

WHAT I DID :

i have context node TXTEDITND with one attribute TXTEDIT type string binded to texteditor in popup view. this context am extending to my view where i have table. so on ok action of that popup window, i get the value of this attribute TXTEDIT. at the same time i get the internal table( LT_ZLOCL_ND) values which is binded to table node (ZLOCL_ND). and i modify perticular row attribute ( PRUEFBEMKT ) with value TXTEDIT. and i bind internal table( LT_ZLOCL_ND) again to node which is binded to node (LO_ND_ZLOCL_ND).

But i am not getting chanaged data to table.

Code :

  • GET TEXT....................................................

DATA LO_ND_TXTEDITND TYPE REF TO IF_WD_CONTEXT_NODE.

DATA LO_EL_TXTEDITND TYPE REF TO IF_WD_CONTEXT_ELEMENT.

DATA LS_TXTEDITND TYPE WD_THIS->ELEMENT_TXTEDITND.

DATA LV_TXTEDIT LIKE LS_TXTEDITND-TXTEDIT.

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

LO_ND_TXTEDITND = WD_CONTEXT->GET_CHILD_NODE( NAME = WD_THIS->WDCTX_TXTEDITND ).

  • get element via lead selection

LO_EL_TXTEDITND = LO_ND_TXTEDITND->GET_ELEMENT( ).

  • get single attribute

LO_EL_TXTEDITND->GET_ATTRIBUTE(

EXPORTING

NAME = `TXTEDIT`

IMPORTING

VALUE = LV_TXTEDIT ).

  • SET UP TEXT............................

DATA LO_ND_ZLOCL_ND TYPE REF TO IF_WD_CONTEXT_NODE.

DATA LO_EL_ZLOCL_ND TYPE REF TO IF_WD_CONTEXT_ELEMENT.

DATA LS_ZLOCL_ND TYPE WD_THIS->ELEMENT_ZLOCL_ND.

DATA LT_ZLOCL_ND TYPE WD_THIS->ELEMENTS_ZLOCL_ND.

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

LO_ND_ZLOCL_ND = WD_CONTEXT->GET_CHILD_NODE( NAME = WD_THIS->WDCTX_ZLOCL_ND ).

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

LO_ND_ZLOCL_ND = WD_CONTEXT->GET_CHILD_NODE( NAME = WD_THIS->WDCTX_ZRES_DIS ).

LO_ND_ZLOCL_ND->GET_STATIC_ATTRIBUTES_TABLE(

  • EXPORTING

  • FROM = 1

  • TO = 2147483647

IMPORTING

TABLE = LT_ZLOCL_ND

).

**********************here i wrote sy-tabix = 1 which is for test purpose, later i will pass perti. index no. so jst ignor it***********

LOOP AT LT_ZLOCL_ND INTO LS_ZLOCL_ND.

IF SY-TABIX = 1.

LS_ZLOCL_ND-PRUEFBEMKT = LV_TXTEDIT .

MODIFY LT_ZLOCL_ND FROM LS_ZLOCL_ND TRANSPORTING PRUEFBEMKT.

endif.

ENDLOOP.

LO_ND_ZLOCL_ND->invalidate( ).

LO_ND_ZLOCL_ND->BIND_TABLE(

NEW_ITEMS = LT_ZLOCL_ND

  • SET_INITIAL_ELEMENTS = ABAP_TRUE

  • INDEX = INDEX

).

Plz try to solve it out.

Thanks ,

Saurin Shah

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • avatar image
    Former Member
    Dec 05, 2009 at 08:56 AM

    HI,

    As already there is a node to whcih the table is bound....with 3 attributes...

    You can use the same 3rd attribute to be shown in the popup for text editor....so that as the user enters there you can see the same in the table 3rd column...

    Why have you taken other attribute.. as the value in the text editor should be reflected in the 3rd column then let that attribute be the part of the node.. this way you can aoivd the modifcaiton to tbale also..

    Regards,

    Lekha.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Then try to create 4 attributes and show the last attribtue fro popup.... in the popup Ok code...as there is a button click per row wise you can pass the index of the clicked row so that based on this index itself you canmove the 4the attribute data to 3rd one for the same row..while clikcing the button iteself pass the row index in the popup you can use the get_element method by passing the index and you can use the set_attribute method to show it in table...this way is easy..

      I didnot understand your select all....concept how will it effect ...

      As per your requriement, where are you facing the problem..

  • avatar image
    Former Member
    Feb 25, 2010 at 03:59 AM

    solved byself

    Add comment
    10|10000 characters needed characters exceeded