AnsweredAssumed Answered

Create URL to edit properties of library document and return to library on Save/Cancel

Question asked by waryoldguy on Aug 14, 2014
Latest reply on Aug 22, 2014 by waryoldguy

To open the EditForm.aspx  to edit properties of a Library document, the format, should be (or is when you perform this in SharePoint):

 

<Site URL>/<List Name>/Forms/EditForm.aspx?ID=<ID>&source=https%3A%2F%2F<server>%2E<domain>%2Ecom%2FList%20Name

 

I am trying to put this together in Workflows 2013 with several string-builders. For instance, one would create the variable LibraryUrl as

fn-XmlEncode({Web-URL}/{Common:ListName})

 

Another variable would hold the variable for the source page string (i.e SourceUrl). It would be assigned via several Set Variable steps

SourceUrl  = fn-Replace({LibraryUrl},':','%3A')

SourceUrl = fn-Replace({SourceUrl},'/','%2F')

SourceUrl = fn-Replace({SourceUrl},'.','%2E')

SourceUrl = fn-Replace({SourceUrl},' ','%20')

 

This is all brought together with another String-builder, and when I hover over the link in the email notification, it appears to be correct. It does navigate to the edit form, but on Save, it opens the item, which is not the desired result.

 

If I simply use a set variable step and enter the text for the source page with colons, slashes, periods and spaces represented by the escape codes it works just fine. Unfortunately we will implement this across numerous libraries and I need to automate it.

 

Any ideas would be most appreciated.

 

Cheers,

   John

Outcomes