on 06-22-2006 10:52 AM
hi all, i have the following problem:
In the controller context, I have a value node with value attributes. The context is filled with data by the wdInit() method.
in the view context, i have mapped the the node to the coresponding controller context.
now when I create a table in the view and bind it to the context node, the data is shown. however, the sequence is all messed up, i.e. the values I added first are now shown on third place (third row) and so on. no alphabetic ordering either, its all messed up. any ideas?
regards, stephan
Hi Stephan,
First of all Welcome to SDN Community!!
Now abt your question..
You can simple order the the column values by ordering of the cloumn in the Outline View of your selected view.
<b>Right Click the table column -> Press Move up.</b>Save and re-deploy.
I hope this helps you.
Regards,
Pravesh
Ps: Please consider rewarding pints for helpful answer.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
thanks for your answers
@oj: yes, my code in the wdDoInit method looks like yours. it's not populated in the view controller though, I use the component controller for that and have the view context then being mapped to the component context.
@pravesh: I am not talking about the ordering of the columns, but of the rows.
this is what's happening in the wdDoInit method
someBOL is a class that I use for building my data (as it is a prototype at this point)
IPrivateLogAnalysis.IComponentElement newComponentNodeElement;
someBOL.initialize();
Collection components = someBOL.getComponents();
for (Iterator iter = components.iterator(); iter.hasNext();) {
SomeBOL.Component comp =
(SomeBOL.Component) iter.next();
newComponentNodeElement = wdContext.createComponentElement();
newComponentNodeElement.setName(comp.getName());
newComponentNodeElement.setSID(comp.getSid());
newComponentNodeElement.setInstance(comp.getInstance());
newComponentNodeElement.setHost(comp.getHost());
newComponentNodeElement.setHostName("hostname");
wdContext.nodeComponent().addElement(newComponentNodeElement);
}
Hi Stephan
Does your populate code in the wdDoInit method look like this:
in a for loop:
for(int i=0; i<10; i++)
{
IPublic<ViewName>View.I<node>Element e = wdContext.create<node>Element();
e.setHeader("Hello");
e.setText("Text_"+i);
wdContext.node<nodename>().addElement(i,e);
}
or could you post the code where u populate it?
regards,
oj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
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.