cancel
Showing results for 
Search instead for 
Did you mean: 

Making checkbox readonly at runtime

Former Member
0 Kudos

Hi there,

I have a table where one of my column is holding checkboxes. I made all the declarations(that is creating column and checkbox) at design time. During run time I need checkbox in some row(based on the value in some other column) should be readonly whereas the checkbox in other row can be editable. So is there any way for doing this.

Regards,

Ponraj M

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Ponraj,

All you need to do is :

1. Create another Context Attribute in the Table's context Node with type 'boolean'

2. Now bind that context attribute to teh checkbox's 'enabled' property.

3. In the code, i.e, in the logic where you are making the current row is read-only there you need to set the context attribute of check box's enabled proeroty to 'false'

This way you can manage the enable disable of the checkbox. Bind the boolean context attribute to checkbox's enabled property.

Thanks,

Raags

Former Member
0 Kudos

Just small addition to (correct) Raghavendra's advise:

If you have model node as table data source (say, from Adaptive RFC Model class or WebService model class) then in [1] create non-singleton value sub-node with cardinality 1..1 and selection 1..1 (initializeLeadSelection=true). Place boolean attribute here.

Valery Silaev

SaM Solutions

http://www.sam-solutions.net

Answers (1)

Answers (1)

Former Member
0 Kudos

Thnx Raags. It worked fine