Inactivating the cascade list

I am trying to inactive the list(level1) of cascade list , I am having 4 list at level 1 but only 2 list are getting inactivated and i get this error:

com.agile.admin.client.value.AdminException: Please cancel this operation and refresh since a newer version of this object is available.
at weblogic.utils.StackTraceDisabled.unknownMethod()
Error code : 20082
Error message : Please cancel this operation and refresh since a newer version of this object is available.
Root Cause exception : com.agile.admin.client.value.AdminException: Please cancel this operation and refresh since a newer version of this object is available.

Code:

IAdmin admin = session.getAdminInstance();
IListLibrary listLib = admin.getListLibrary();
IAdminList list = listLib.getAdminList(“TestList”)
IAgileList values= list.getValues()
IAgileList[] parent=(IAgileList[])values.getChildren();
for(int i=0;i<parent.length;i++)
{
parent[i].setObsolete(true);
values.addChild(parent[i]);
list.setvalues(values);
}

How can i update it?

Agile User Asked on May 26, 2022 in Product Collaboration.
Add Comment
1 Answer(s)

I may not be the right person to answer this, but since no one else has tried…

Based on your error message (and the code in your loop), it looks like you are attempting to obsolete a value and then add a value at the very same parent index.  Actually, it looks like you’re obsoleting the parent and then trying to add a value to that parent.  If you’ve obsoleted it, the object is likely no longer valid.  You may have to do separate loops… one to obsolete,  then get the objects fresh and loop through to add what you need to.  This is not my area of expertise, but clearly you’ve altered an object and then attempting to do something with that object afterward. Is there some “refresh” command that you can instantiate somewhere within there?

Steve L.

Agile Professional Answered on June 9, 2022.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.