cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Not applicable

Need help with a collection operation.

Jump to solution

I am having some trouble.

I have a list that tracks an issue through to completion.

Then I have a document library with a "TrackingID" field to match the item on the list for each document related to that item.

 

Here is my problem.

When a document is ready to publish, it is copied to a temporary library so the publisher will only see THOSE documents, thus reducing error.

The part that crashes is if the document is checked out to anybody, the checked out document will not copy and will also cause my workflow that copies the item to error.

 

My goal is this:

When the final approval is done, the item is flagged for publishing, which kicks off the workflow to copy the document into the temp library.

 

What I need is a way for the workflow to look into the document library and find all the documents related to that ID, and gather the checkout information.

 

Next, I need it to somehow compile that information into a text field that can be updated in the list.  Then, this will be sent back to the person who approved the item in the first place, tell them that the item(s) are checked out (and to who), so they need to address this issue then come back and update the item that it is ready to publish again.

Labels: (1)
Tags (1)
0 Kudos
Reply
15 Replies
Highlighted
Nintex Newbie

Re: Need help with a collection operation.

Jump to solution

Why send the documents to the temporary library. Why not change the permissions for only the publisher to see those documents? That should reduce the error.

0 Kudos
Reply
Highlighted
Nintex Newbie

Re: Need help with a collection operation.

Jump to solution

You should be able to query the document library based on the ID.  Then go through the collection, evaluating the field [Checked Out To].  If it is empty, assume that it is not checked out.  If it has a value, use the Build String action to compile the information.  Then set the field in your list to the string you just built.

10-14-2015 12-15-22 PM.png

10-14-2015 12-15-54 PM.png

10-14-2015 12-17-48 PM.png

This is how you set up the collection operation.  You can repeat for how many ever fields you gathered on the initial query.

10-14-2015 12-02-30 PM.png

We have to get the first name and last name, then use the build string action to combine them to get a full name.

10-14-2015 12-19-15 PM.png

Instead of sending a notification at the end, you can update the item with the text field. 

0 Kudos
Reply
Highlighted
Not applicable

Re: Need help with a collection operation.

Jump to solution

Hi Sally let me understand you better, why it is the problem that document is checked out ? Is there are need to check out documents ? If there is a need of that you can you actions which lets check in your documents. So you just need to query them on your tracking ID with Query list action.

As the answer to "What I need" part i could suggest you using Query list action on your TrackingID.

It is hard to understand what process you are trying here to automate, but if you could tell how this process is called we could suggest you the best way of doing that.

0 Kudos
Reply
Highlighted
Not applicable

Re: Need help with a collection operation.

Jump to solution

The reason for the temporary library is that the publisher will be using windows explorer to do what they need with the documents.  If I leave them in the existing library, then the publisher will have to filter through hundreds of documents within a year from now since views/filters don't apply in explorer, severly impacting the efficiency and possibly increasing the potential for error (grabbing the wrong document).

The documents are put in the temp library, then deleted when publisher is done.

0 Kudos
Reply
Highlighted
Not applicable

Re: Need help with a collection operation.

Jump to solution

Thank you.

In my test library I have 3 documents, 2 checked out, all have trackingID=1. My test list has just the one issue for tracking, ID=1. I was hoping to be able to link somehow via that tracking ID(library)=ID (list).

I tried the query list and all the steps you have above, but when I got the notification it was blank.  I tried including all the variables and fields set via the variables into the notification, and the most information I was able to have showing in the email was the tracking ID number.

I just can't wrap my head around or understand how this collection operation works.  It is just too confusing to me and/or maybe i just have too much on my mind to let it sink in.

If anyone knows of a good resource that gives a deep explanation of how this thing works, please post a link!

0 Kudos
Reply
Highlighted
Not applicable

Re: Need help with a collection operation.

Jump to solution

The documents need to be checked out for editing.  That was decided by our workgroup.

The documents need to be checked in so they can be copied into another library where the final items go.

If they are checked out when the workflow tells SharePoint to copy item, then I get a "workflow errored" message, because document is checked out.

I tried to query list, but I don't understand how to use the collection variables, etc.

problem, document library might have more than 1 document for a list item (the issue we're tracking), and I want to be able to have a workflow on that list to somehow look at the library where trackign id=list item ID and let me know if any documents with that ID are checked out so I can stop that workflow and send a notification to the approver that one or more documents are checked out.  At this point I don't even care who has it checked out, just so I can get the information that 1 or more is checked out so I can send a notification to someone and end the workflow before it errors.

0 Kudos
Reply
Highlighted
Nintex Newbie

Re: Need help with a collection operation.

Jump to solution

Sally, try enabling verbose logging and make sure that you can see how many times the loop is running.  This will also let you know how to see what your workflow is doing and where it may behaving issues.

0 Kudos
Reply
Highlighted
Not applicable

Re: Need help with a collection operation.

Jump to solution

Forgive me for being uninformed, but exactly what is verbose logging and what does that do?

I am not an administrator, I am just trying to design our workflow process for this project.  My permissions are limited to full control on the site.

0 Kudos
Reply
Highlighted
Nintex Newbie

Re: Need help with a collection operation.

Jump to solution

No problem.  Verbose logging will allow you to view the value for all workflow and system variables at each step.  This is useful for troubleshooting because you can see when and where a variable is not being set properly.

To enable the verbose logging, go to the workflow settings.  You will see a check box for verbose logging. 

Check it and run the workflow.  Once the workflow is complete, view the workflow history. 

Clicking on any of the actions will open a popup window that will display all of the workflow and system variables.  Variables marked in yellow were changed during that action.

0 Kudos
Reply