on 12-04-2007 12:48 PM
Hey all
Please try to help..
I have a table with data I am getting from a backbend system, to that table I want to add radio buttons in every row, how would you l do that? I tried to add a column with a cell editor of radio button,. but I am getting it disabled.
Thanks
Hey
SOLVED
Don't forget to set the Table to be "readonly" --> false , and set it to be nonselectable by changing "rowSelectable --> false" and "selectionMode --> none"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You have to specify a context for the selected key and key to select property of the UI elements to enable it.
Regards,
Murtuza
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
After binding the context to the radio button UI element you got the radio button enabled or not?
You are going in a right direction.
1. Create a column in table.
2. set the cell editor as Radio button.
3. Bind its property selected key and key to select.
Now run the application. You should get radio buttons enalbed on the screen.
Hope, you are not checking it at design time.
Regards,
Murtuza
Hi Oren
If you done everything correct as said in the above conversation:-
Then check the following things
(1) Let say, you have binded your table's datasource property with "NODE1"
(2) Then your radio button's property selectKey and keyToSelect should come under same context node "NODE1".
(3)If you use any other node like "NODE2" for this then your radio button will be disabled because of cardinality
Regards,
Praveen
Hi Praveen
well I connected the selected key to a new attribute that holds data from the table, the keyToSelect I tried connecting to a different attribute and to nothing but simple text and still no luck, the thing is that I either get it disabled and already marked or empty and I cant mark them
Hi oren,
you have to implement the action onSelect of radio button.
I will give a way to test it.
(1)First populate your table node.
(2)Then create method for OnSelect action of radiobytton.
(3)Now write the following code there.
IWDNodeElement element=wdcontext.node<TableNodeName>.getcurrentElement();
element.setAttributeValue("SelectedKey",true);
Now when you click on any radio button, this method will be called and you can select or deselect the selected radio buttons.
Regards,
Praveen
Regards,
Praveen
Pravven
Hey thanks alot but still I miss something, now I made a new node with the right cardinality but singeltone true cause it wont let me to change it, any how I created the attribute "key1", bind the radio button both selectedkey and keytoselect
to the attribute, implemented the action and still I get it disabled and marked (the radio buttons).
now another question is why in your method you wrote
element.setAttributeValue("SelectedKey",true); the ",true" is not right cause it wanst an element not a boolean so I guest its the attribute key1 right???
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.