on 05-22-2006 10:51 PM
I have a drop down by index UI element which gets its values from a table. i need to set the default value to 'Select a State' or something like that. How do i do it?
Thanks,
Lathika
Hi
Try the code below.
IPrivate<View_name>.I<Node_name>Element ele = wdContext.node<node_name>().create<node_name>Element;
wdContext.node<node_name>().addElement(ele);
wdContext.current<node_name>Element.set<attribute_name>("Select a State");
//Again create element and add the table values to ur node.
wdContext.node<node_name>().setLeadSelection(0);
But this will contain the value 'Select a State' at the index 0.
Regards,
Rathna.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hai Lathika,
ArrayList arr=new ArrayList();
IPrivateXXXXXView.IXXXElement yElement =wdContext.createXXXElement();
yElement.setZ("-select Position-");
arr.add(yElement);
wdContext.nodeXXX().bind(arr);
try this,
regards,
Naga Raju
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Lathika,
Please follow these links:
and
Also, try this solution:
that means you have to set at design time,
to set default drop down value you will have to set the value for particular attribute (which is linked to the dropdown element) in the context
like
wdContext.currentContext<nodeName>Element.set<FieldName>(<default value>)
This generally done in Initialization method of the controller
Thanks,
Raj.
Message was edited by: Raj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.