on 12-26-2006 11:22 AM
Hi All,
I have created a simple type in Dictionary. With some Key and value pair. I want to bind this simple type to a table column.
Does any body have suggestion how can I do that?
Regards,
Maya.
As Armin suggested u have to add elements to ur context node to display values in ur table.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Monalisa,
I try to take Input Field as table cell editor,
It works fine, but I would like that the values of the simple type will be shown in the Input Field on the same table, not in different one.
Thanks,
Maya.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Take Input Field as your table cell editor.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Maya,
There is another solution for ur Prblm.
Plz let me know if ur table is having any key,Value(desc) for that perticular dropdown.If it is ther means u can populate the dropdown By using this code.
1.ISimpleTypeModifiable objXX = null;
2.IModifiableSimpleValueSet objYYY = null;
objXX = wdThis.wdGetAPI().getContext().getModifiableTypeOf("ctx_ConveyanceType");
objYYY = objSimpleTypeConveyanceTypeData.getSVServices().getModifiableSimpleValueSet();
3.Get the size of that Table and get the Key and Value Descriptions.
4.Finally set it to DropDown
ex:objYYY .put(key,ValueDesc);
One more thing u need to create one string attribute for that Dropdown lik:ctx_strXX,type is string.
Populate this dropdown using above Code.
This method is applicable only for table coontains Key,Value for that Dropdown.
Let me know if u hav any doubts,
Regards,
Lavanya.G
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Create a context attribute of type simple type that you have created. Then add a TableCellEditor to your table column and bind the value or text property of that editor to the context attribute.
Regards,
Satyajit.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Give "tableNode" cardinality 0:N.
To display table rows, you have to create and add elements to the data source node. For example with code like
for (int i = 0; i < numRows; ++i)
{
ITableNodeElement e = wdContext.nodeTableNode().createTableNodeElement();
wdContext.nodeTableNode().addElement(e);
e.setHourAttribute(<some-value>);
}
Armin
User | Count |
---|---|
80 | |
9 | |
9 | |
7 | |
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.