Hi,
I was hoping to get some help with a problem I'm trying to solve. Here' the situation:
A sample workflow with attachments has been set up as follows:
workid = subworkid = 30700699
attachment container = 30700693
desktop attachment = 30700694
livelink attachment = 30700695 (original dataid = 1526347)
and here's what I'm trying to do. Given the attachemnt id (in this case 30700695), can we somehow get the value of the original dataid? (in this case 1526347)
I know the data is stroed in the dTree table in the field ExtendedData in the following format:
A<1,?,'WF_OrigID'=1526347>
So I know I can retrieve this data via SQL queries if necessary. However, if this can be done through web services somehow, that'd be the prefered route.
I thought I was on to something with the following code:
Node node = fDocManService.GetNode(fDocAuth, NodeID);
DocumentManagement.Version version = fDocManService.GetVersion(fDocAuth, NodeID, 1); //default to 1 for now as we know for sure there is only 1 version on the current node
Node providernode = fDocManService.GetNode(fDocAuth, version.ProviderID);
This failed as providernode becomes a null, but I noticed the version.ProviderID was only 1 off of the actual nodeID i was looking for, so changing it to
Node providernode = fDocManService.GetNode(fDocAuth, version.ProviderID - 1);
gets me the node I wanted. However, I'm assuming this was a case where it just "happened" to work out like that for NodeID 30700695 and original data id 1526347, and wont be consistent.
Any advice or solutions you guys can provide would be great.
Thanks