Nintex Connect

The Official Community Site for Nintex Software Products, including Nintex Workflow 2007, 2010 and 2013; Nintex Workflow for Project Server 2010; Nintex Reporting 2008 and Nintex Analytics 2010; Nintex Forms 2010; Nintex Live and Nintex SmartLibrary.
Welcome to Nintex Connect Sign in | Join | Help
in Search

Call Web Service: Opening List Attachment URLs from an Email Notification in Edit Mode

Last post 12-03-2009, 10:07 AM by Anonymous. 0 replies.
Sort Posts: Previous Next
  •  12-03-2009, 10:07 AM 7612

    Call Web Service: Opening List Attachment URLs from an Email Notification in Edit Mode

    The following workflow was designed to loop through multiple List attachments, capture their URL, then embed them into a “Request Approval” action so that approvers can open the attachments from the email notification in Edit mode then modify them without having to access the List item directly from SharePoint.


    Declared 4 workflow variables using the variable types as shown below:




    Here’s a screenshot of the workflow structure:




    The actions are configured as follows:

    The “Call web service” is using the Web_Url lookup then the /_vti_bin/Lists.asmx extension which is a mandatory field that represents the full URL of the SOAP Web service to call. Once a URL has been entered, the Refresh button can be pressed to define the available methods.



    The parameters are stored within the var_AttachmentXML workflow variable.


    The “Regular expression” action removes the XPath namespace (e.g. xmlns="http://schemas.microsoft.com/sharepoint/soap/") as leaving it in would make it more difficult to write the XPath expression.




    The “Query XML” action is querying the XML variable using the XPath expression //attachments/attachment to pull out the value inside the Attachment XML node for each Attachment node then storing them in our defined collection variable var_CollectionURLs.




    The “For Each” action is used to store the var_CollectionURLs variable data within a text variable to be used in the “Build Dynamic String” action for each attachment.




    The “Build Dynamic String” action uses the var_AttachmentURL data and converts it into a URL that can be embedded into the email notification. (Note that this is a part of the “For Each” action, so it will continue to loop through all List attachments.)



    {WorkflowVariable:var_AttachmentLinks} à this is being included so that the previous loop’s data is not overwritten

    <a href="{Common:WebUrl}/_layouts/nintexworkflow/opendocforedit.aspx?doc={WorkflowVariable:var_AttachmentURL}&page={Common:WebUrl}&close=true">{WorkflowVariable:var_AttachmentURL}</a> à This string builds the URL so that it can be opened in Edit Mode within the email notification. Additionally, it includes HTML tags so that the URL will be displayed as a hyperlink. (This is really necessary if spaces were included in your site/list name as spaces will sometimes break hyperlinks.


    The “Request Approval” action includes the var_AttachmentLinks within the “Edit Approval Required Notification” body which will now reflect all attachment links. Again, these links will open in Edit Mode from the email making this process easier for approvers.



    Note that you will want to also update the Approvers field on this action so that it reflects the correct approvers.




View as RSS news feed in XML
Powered by Community Server, by Telligent Systems