Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
Update Body property of IManLinkListFolder
JayAchTee
I am trying to update the Body property of a IManLinkListFolder and am getting an exception just getting the existing Body string. I get the message "[Folder ][Task Body(get) ]The bodied folder doesn't have exactly one document". We are running WorkSite 8.2 SP4.
What's odd is the "Task Body" in the above exception but the folder is definitely a IManLinkListFolder as it's nrl is "!nrtdms:0:!session:~~~:!database:~~~:!LinkListFolder:61557::" as shown in my application's log file (the ~~~ was inserted to prevent icons in the post). The application is a custom C# application that can add a IManLinkListFolder to a Workspace using the Body property but not update the Body property.
Has anyone been able to get this to work?
Find more posts tagged with
Comments
dopey
If you just ignore the little peccadillo about task folder (which comes of copying code), isn't it a great error message? It's not like "Socket Error" where you're left scratching your head, but it tells you exactly what's wrong. You've got the wrong number of documents in a LinkList folder and the imanage.dll is stumped.
So the problem is that a link list folder is really a folder with a document in it, the document storing the body of the folder. Your link list folder either has zero documents in it, in which case you're sunk, or it has more than one, in which case you're sunk too. When I ran some sample code creating a link list folder, it appears that the document gets when you call IManLinkListFolders.AddNewLinkListFolder (etc.). So why you would have a link list folder without exactly one document in it is beyond me.
You can check it out by looking at your database's Project_Items table. If you look for PRJ_ID = your folder's project, from the moniker, it's likely you will see either that the number of items is unequal to one.
I think the solution is to try creating a new linklist folder and see if you get the same problem. If you can figure out how to reproduce the problem, make sure you send it in to dev support.
JayAchTee
Thanks for the input ... that helped our DMS administrator find out that somehow an import from WorldDocs had dumped quite a few documents in the LinkListFolders. He cleaned up the project items table and it seems to be working now.
It's odd how the LinkList would display on the web side just fine even though my application could not even read the body.
dopey
The body is a late-bound property, so if the web isn't displaying it everything should work fine. If it was displaying the body properly, that's really cool.