on 11-28-2007 8:02 AM
Hi Experts
I created a dictionary simpletype "People" with two values male and female.
and i created a value attribute "people" and bind this attr to the prop of selected key of ui element.
iam able to see the radiobuttons in design time but iam not able to see at runtime.
Plz provide me solution
Thanks & Regards
Hazrath.G
Hi,
You have to bind the values to the UI Element Externally from SimpleType..incase
of RadioButtonGroup
Put the value attribute <Value> of Type String as child of a ValueNode, Say <TestNode>
and Take another Value attribute as child of conetxtNode <attr> of Type <SimpleType>
Then Use this code
IWDAttributeInfo objAttrInfo=wdContext.getNodeInfo().getAttribute(IPrivate<Viewname>.IContextElement.ATTR);
ISimpleTypeModifiable simple=objAttrInfo.getModifiableSimpleType();
Map m=simple.getEnumerationTexts();
Collection c=m.values();
Iterator it=c.iterator(); ArrayList al=new ArrayList();
while(it.hasNext())
{
IPrivate<ViewName>.I<TestNodeElement> element=wdContext.create<TestNodeElement>();
element.set<Value>(it.next().toString);
al.add(element);
}
wdConetxt.node<TestNode>().bind(al);
Hope this solves
Ragards
LakshmiNarayana
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Lakshmi ,Thanks for ur immediate reply.
I have solved the above problem,i have done mistake like below
I have not changed the default datatype of value attributre type string.
I have one more question:
I want to select one option defaultly.
Plz give me the solution
Thanks & Regards
Hazrath.G
User | Count |
---|---|
84 | |
24 | |
12 | |
9 | |
7 | |
6 | |
5 | |
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.