cancel
Showing results for 
Search instead for 
Did you mean: 

Making a table to appear and disappear on clicking a button

Former Member
0 Kudos

Hi,

I want to make a table to appear and disappear within the view on clicking a button which is also present in the same view.

Please let me know whether it is possible or not..If possible please provide me with the steps..

Thank you .

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

hi,

create a boolean attribute in your context then map the boolean attribute to the visibility attribute of your table UI element.

in the action of your button just set the attribute

wd_context->set_attribute( name = 'name of your boolean attribute" value = 'X' ).

if you want to not make it visible then:

wd_context->set_attribute_null( name = 'name of your boolean attribute" ).

thanks!

Jason PV

ChrisPaine
Active Contributor
0 Kudos

Hello,

just because it's one of my little foibles:

create a visibility attribute in your context of type WDUI_VISIBILTY then map the visibility attribute to the visibility property of your table UI element.

in the action of your button just set the attribute


wd_context->set_attribute( name = 'name of your visibility attribute' 
                           value = cl_wd_uielement=>e_visible-visible ).

if you want to not make it visible then:


wd_context->set_attribute( name = 'name of your visibility attribute' 
                   value = cl_wd_uielement=>e_visible-none ).

you can read the current settings of the attribute and inverse it using a simple read - if else construct.

Cheers,

Chris

Answers (0)