Skip to main content
Nintex Community Menu Bar
Solved

Need help looking up Document Set welcome page link and setting it in a feild in another list

  • December 1, 2016
  • 10 replies
  • 223 views

Forum|alt.badge.img+3

Hi ,

 

I have 2 lists. First list is a claims register and when an item is created it creates a document set in a Claims File document library configured for Document sets. On creation it stores the item ID and the item URL in variables. I have this working all fine. I next want to set a field in the Claims Register to link to that Claims file. When I set the field to the workflow variable storing the item URL it only links to the display.aspx for that item. I would like it to link directly to the welcome page of that Document set created. I have tried doing a lookup and storing the name field in a variable but that doesn't seem to work. Workflow is suspended due to input string not a correct format. Am I looking up the wrong field to achieve this?

Best answer by philipplucas

Can you try to use a "Build string" action and create an anchor tag for your url and use your items name as display name for the link. Save it to a variable and use this variable to update your field.

10 replies

Forum|alt.badge.img+11
  • 633 replies
  • December 1, 2016

Hi Katie,

unfortunately there is no standard property/field of the docSet that you can query to get the link to the homepage of the doc set, at least none I know about. Therefore you will need to construct this URL yourself. Fortunately you do not have to rebuild the whole URL you see in the browser when navigating to the page.

What you basically need is this:

http://[WebApp]/[Manage Path]/[SiteCollection]/[Web]/_layouts/15/DocSetHome.aspx?id=http://[WebApp]/[Managed Path]/[SiteCollection]/[Web]/[DocSet Library Name]/[DocSet Name]&DefaultItemOpen=[DocSet ID]

This may look like a lot of work but it's rather simple to build. You can use a "Build string" action inside your workflow to build up this URL.

As you can see I'm heavily using the WF-Variable "WebUrl" which is always available and holds the URL of the web your workflow is running on. The "/_layouts/15/DocSetHome.aspx?id=" has to be hard coded here. Be aware that "15" is for SP 2013. If you have another SP Version you may need to change the hive number. Afterwards we use the "WebUrl" variable again. Then we need the name of the library where the doc set is stored in. Here I just wrote in the name of the library which is "DocSets" in my case. But you may also provide another variable here to keep it dynamically. Same is for the name of the document set which is "DemoSet01" in my case. The part "&DefaultItemOpen=" needs to be entered manually again. At last you need to enter the ID of your document set but you are having this ID anyway from the doc set creation.

This link will then bring you to the homepage of your document set.

Hope this helps.

Cheers

Philipp

Edit: I Forgot that you asked about o365. At the moment I only have access to an onPrem SharePoint and cannot test this for o365 but I hope my answer is still valid for o365 SharePoint!


Forum|alt.badge.img+3
  • Author
  • 18 replies
  • December 6, 2016

Forum|alt.badge.img+11
  • 633 replies
  • December 6, 2016

Hi Kate,

still can't test it myself on o365 but did you try to just use the bold section? Does it work already?

If it doesn't we can still try to create what you see in the URL. But I recommend you try to shorten this url if possible. For example the "RecSrc" part could be not necessary.

However, he we go with the parameters:

FolderCTID: Thats the GUID of the folder where the "folder" should be your document set. Since the ID of the document set content type should always remain the same (as long as you don't use your own document set content type) you can just copy this ID for your url string.

List: Thats the GUID of the list (in this case your document library) where the workflow is running on. If your workflow is only supposed to work for the lists you mentioned, you should be able to just copy this GUID as well. List GUID won't change until you re-create the list or use another one.

RootFolder/RecSrc (same value): Actually I'm not sure about this one.  You can try to use a "Query List" action on your recently created document set (filter the query list action on the docset library with your item ID) and see if you get some property that holds this value.

Maybe someone else with access to an o365 account can support us ^^

Regards

Philipp


Forum|alt.badge.img+3
  • Author
  • 18 replies
  • December 8, 2016

I did try the above but it cuts the string at 250 characters. Is there a limit that you are aware of? Can’t seem to find anything on google.

I also tried just the bold section but that doesn't open the link as needed


Forum|alt.badge.img+11
  • 633 replies
  • December 8, 2016

Hi Katie,

here you find some information about URL path length restrictions in SharePoint. Article is for SharePoint 2010 but afaik this information is still valid for 2013.


Forum|alt.badge.img+3
  • Author
  • 18 replies
  • December 13, 2016

Thanks I will have a read through that.


Forum|alt.badge.img+3
  • Author
  • 18 replies
  • December 14, 2016

Hi Philipp, I haven't been able to figure it out and for the life of me can't get it back to the result I originally had that was linking to the display form. I have done the update list item action and set the field to the DocSetURL variable but I can't get it to display a display name (Name field) instead of the full url. Any chance you know?


Forum|alt.badge.img+11
  • 633 replies
  • Answer
  • December 14, 2016

Can you try to use a "Build string" action and create an anchor tag for your url and use your items name as display name for the link. Save it to a variable and use this variable to update your field.


Forum|alt.badge.img+3
  • Author
  • 18 replies
  • December 15, 2016

Thanks, I did it using build string and update field. I had been doing that several times but with all the attempts corrupted the hyperlink field it was updating. I deleted the field and started again and it worked. Thanks for all your help.


TomaszPoszytek
Forum|alt.badge.img+17

‌ can you mark any from the questions as "Correct" if it helped you?

Regards,

Tomasz