You are viewing limited content. For full access, please sign in.

Question

Question

Make Token for "Document Owner" or "Created By" characteristic ?

asked on July 30, 2014

I'd like a workflow to perform the following, sort documents into folders by the User that Created or Owns the Document.

 

Problem is that there are not any available tokens for document properties such as Created By or Document Owner.

 

Seems like I need to create a token, and somehow assign it to be the 'Created By" or "Document Owner" characteristic, but can't make this happen.

 

(Once I get the token I know how to get Workflow to create folders and route the entries to those folders, but first I need a way to Capture the Creator of the doc to use in a token for folder creation.

 

LF Workflow 8.3

 

0 0

Answer

SELECTED ANSWER
replied on July 30, 2014

VB:

 

SetToken("Owner", me.Entry.OwnerName)
SetToken("Creator",me.Entry.CreatorName)

C#:

 

SetToken("Owner", this.Entry.OwnerName)
SetToken("Creator",this.Entry.CreatorName)

Just add the 2 lines in the SDK Script activity's script editor right after the line that says "Write your code here". Then make sure the Script Tokens pane is open in the script editor and click the button labeled "Auto-detect Tokens".

1 0

Replies

replied on July 30, 2014

These features have been added in 9.1. In 8.3, you could get the values using an SDK script.

0 0
replied on July 30, 2014

and here is where I hope someone has said script ready to copy and paste....I'm not a developer, but it can't be that hard....

 

Help ?  Anyone ?

0 0
SELECTED ANSWER
replied on July 30, 2014

VB:

 

SetToken("Owner", me.Entry.OwnerName)
SetToken("Creator",me.Entry.CreatorName)

C#:

 

SetToken("Owner", this.Entry.OwnerName)
SetToken("Creator",this.Entry.CreatorName)

Just add the 2 lines in the SDK Script activity's script editor right after the line that says "Write your code here". Then make sure the Script Tokens pane is open in the script editor and click the button labeled "Auto-detect Tokens".

1 0
replied on July 30, 2014

MIRUNA YOU ARE AWESOME

 

 

YOU'VE BEEN AWESOME.

 

YOU CONTINUE TO BE AWESOME.

 

THANKS !  THIS SAVED US HOURS !

 

 

YOU DESERVE A RAISE !

0 0
replied on July 30, 2014

How do you do this in Workflow 9.1?  I'm searched and searched, but can't find how to use the Creator token.

 

LF Workflow 9.1

1 0
replied on July 30, 2014

In 9.1, when you run Find Entry, Find Entries or Search Repository activities, you can specify additional properties to retrieve for the documents.

1 0
replied on July 30, 2014

What if the workflow is triggered by an Entry changing (Condition).  Do I still have to perform a Find Entry if the entry is what triggered the workflow?

1 0
replied on July 30, 2014

I got this to work by adding a Find Entry at the beginning of the work flow, and searching for the initiating Entry ID, then adding Created By to the Additional Properties section of that task.

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.