Skip to Content
avatar image
Former Member

calling another table

Hi every one

I have a quistion plese go through it.

I created a table in a view and it have summary button.when we click on summery another summery table will open.

before click that summary table should be hide and after click it will open and displays values...

can any one tell me how to do it.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Nov 24, 2011 at 04:48 PM

    Hi,

    Create an attribute of type WDVisibility(com.sap.ide.webdynpro.uielementdefinitions.Visibility)

    In the datatype property of context attribute click on search icon->Dictionary Simple type->Local dictionary->com.sap.ide.webdynpro.uielementdefinitions->Visibility.

    eg: u created a attribute called visible of type mentioned above.

    1.Bind this to the visible prperty of summary table.

    2.In wdDoInit() of the view set

    wdContext.currentContextElement.setvisible(WDVisibility.NONE);
    

    3.Now on action of summary button set it to visible.

    wdContext.currentContextElement.setvisible(WDVisibility.VISIBLE);
    

    Now the table will be visible when th button is clicked.

    Let me know if you face any issue.

    Regards,

    Anand G

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 25, 2011 at 06:30 AM

    Hi,

    You can do this by binding the Visibility property of the Table UI element to an context attribute of the type Visibility.

    For that,

    1.) First create an context attribute say "table_visibility" in the context.

    2.) Give its type as Visibility.

    For that, right click take the properties of the table_visibility attribute and take the binding option. Then under Dicitionary Simple Type, find for com.sap.ide.webdynpro.uielementdefinitions and expand the node. You will find Visibility under it at the bottom. Select Visibility by double clicking it.

    3.) Now take the Table UI element, and take its properties. Bind the property Visible of it with the attribute "table_visibility".

    4.) Now take WDDoInit() method of the view and give the following coding:

    wdContext.currentContextElement().setTable_visibility(WDVisibility.NONE);

    5.) Take the event handler method of the summary button and write the following coding:

    wdContext.currentContextElement().setTable_visibility(WDVisibility.VISIBLE);

    Now it will work as you desired.

    Hope this will help you.

    Regards,

    Jithin

    Add comment
    10|10000 characters needed characters exceeded