on 05-07-2007 2:36 PM
Hi All,
Node strucure is
-->Prospect(Value Node)
-->Opportunity(Value Node)
--> Opportunity ID(Value attr)
-->ProspectID(Value attr)
-->Prospect Name(Value Attr)
int nProspectOppNodeSize = wdContext.nodeZopportunity().size();
IPrivateStaffingView.IProspectNodeElement eleProspect;
IPrivateStaffingView.IOpportunityNodeElement eleOpportunity;
wdContext.nodeZopportunity().moveFirst();
for(int i=0;i<nProspectOppNodeSize;i++)
{
eleProspect = wdContext.nodeProspectNode().createProspectNodeElement();
wdContext.nodeProspectNode().addElement(eleProspect);
eleProspect.setProspectID(wdContext.currentZopportunityElement().getProspect_Id());
eleProspect.setProspectName(wdContext.currentZopportunityElement().getProspect_Name());
String strCurrentProspectID = wdContext.currentZopportunityElement().getProspect_Id();
while(strCurrentProspectID.equalsIgnoreCase(wdContext.currentZopportunityElement().getProspect_Id()))
{
eleOpportunity = wdContext.nodeOpportunityNode().createOpportunityNodeElement();
wdContext.nodeOpportunityNode().addElement(eleOpportunity);
eleOpportunity.setOpportunityID(wdContext.currentOpportunityNodeElement().getOpportunityID());
wdContext.nodeZopportunity().moveNext();
}
wdContext.nodeZopportunity().moveNext();
}
wdContext.nodeZopportunity().moveFirst();
int nProspect = -1;
for(int i=0; i<wdContext.nodeZopportunity().size(); i++)
{
if(wdContext.currentDisplReq_Zsr_MasterElement().getProspect_Id().equalsIgnoreCase(wdContext.currentProspectNodeElement().getProspectID()))
{
nProspect = i;
}
wdContext.nodeProspectNode().moveNext();
}
wdContext.nodeProspectNode().moveTo(nProspect);
Please help
Hi ,
WD code cant restart your java engine.. It might be that your code is running in infinite loops eating up heaps of memory..
Check this line..
for(int i=0; i
<b>><</b>
wdContext.nodeZopportunity().size(); i++)
Regards
Bharathwaj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello,
I think the problem is that you are not controlling the end of this bucle:
String strCurrentProspectID = wdContext.currentZopportunityElement().getProspect_Id();
while(strCurrentProspectID .equalsIgnoreCase(wdContext
.currentZopportunityElement().getProspect_Id()))
{ ...
wdContext.nodeZopportunity().moveNext();
}
you can do something like:
int count = 0;
int num_ele = number of elements of node Zopportunity
while (<b>count<num_ele</b> && strCurrentProspectID .equalsIgnoreCase(wdContext
.currentZopportunityElement().getProspect_Id()))
{
...
wdContext.nodeZopportunity().moveNext();
<b>count++;</b>
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello,
I think the problem is that you are not controlling the end of this bucle:
String strCurrentProspectID = wdContext.currentZopportunityElement().getProspect_Id();
while(strCurrentProspectID .equalsIgnoreCase(wdContext
.currentZopportunityElement().getProspect_Id()))
{ ...
wdContext.nodeZopportunity().moveNext();
}
you can do something like:
int count = 0;
int num_ele = number of elements of node Zopportunity
while (<b>count<num_ele</b> && strCurrentProspectID .equalsIgnoreCase(wdContext
.currentZopportunityElement().getProspect_Id()))
{
...
wdContext.nodeZopportunity().moveNext();
count++;
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
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.