
HOW DO I… A Quick Lesson for ProjectSolveSP Users Topic: Creating an Auto-Number Using Nintex Workflow Category: Tools and Objects User Level: Member (Coordinator) Prerequisite: How Do I … Create Lists within ProjectSolveSP? How Do I … Add a Nintex Workflow to a ProjectSolveSP Library? Overview One of the features missing in ProjectSolveSP that was available in ProjectSolve2 is the automatically generated number (auto-number) that was available to users with the ProjectSolve2 Database object. While ProjectSolveSP lists and libraries do have an ID number feature out of the box, it automatically starts at “1” and increments numerically. Additionally, if you delete a file from that list or library, the ID number that had been assigned to that item is gone for good. To fix this issue, the process outlined within this document uses a source number list and the Nintex Workflow for SharePoint application to create a customized auto-number that can be added to uniquely identify items within any list or library. This approach allowed us not only to automatically assign identification numbers to entries within a list or library, but to also reset those numbers as needed when test data is removed. Scenario For this lesson, we are going to create a document library where each entry into that library is assigned a unique ID number that reflects the name of the project. The name of our project will be “Bridge ABC” and the ID number for each document will be “ABC-xxxx” (where “xxxx” will be “0001” thru “9999” as needed.) Steps Create the Number Source List The first thing we will do is to create a new list called “Master Numbers” and use this to establish the current source number for our workflow. Create the List To create our “Master Numbers” list: 1. Access the ProjectSolveSP site where we will be working. 2. Click the “Settings” button ( ). 3. Click the “Add an App” link on the Settings menu. 4. Click the “Custom List” icon. 5. Set the name to “MstrNums” (remember this name becomes part of the URL, so keep it short but descriptive, and then expand it once the list is made.) 6. Click the “Create” button. The list is now available for use. Modify the Master Number List 1. Access the new “MstrNums” list. 2. Click the “List” tab. 3. Click the “List Settings” button. How Do I… Create an Auto-Number using Nintex Workflow 1 V1.2/0417 © WSP USA, 2017 HOW DO I… A Quick Lesson for ProjectSolveSP Users Reset the Name of the List 4. Click the “List Name, Description and Navigation” link: Figure 1 - The "List Name, Description and Navigation" Link 5. Change the “Name” field from “MstrNums” to “Master Numbers”. 6. Leave the “Display this list on the Quick Launch?” set to “No” 7. Click “Save” to return to the settings page. Create the “Source Number” Column 8. Click “Create Column” in the “Columns” area: Figure 2 - The "Create Column" Option 9. Set the Column Name to “Source Number.” 10. Set the Column Type to “Number” (Figure 3): How Do I… Create an Auto-Number using Nintex Workflow 2 V1.2/0417 © WSP USA, 2017 HOW DO I… A Quick Lesson for ProjectSolveSP Users Figure 3 - The "Configure Column" Screen 11. Click “OK” to complete the process. How Do I… Create an Auto-Number using Nintex Workflow 3 V1.2/0417 © WSP USA, 2017 HOW DO I… A Quick Lesson for ProjectSolveSP Users Create the Seed Entry Once the list is ready we need to create a seed entry that will be used by the workflow. 1. Access the “Master Numbers” list. 2. Click “New Item.” 3. Name your item “Master Record.” 4. Set the “Source Number” to “1.” 5. Click “Save.” Your “Master Numbers” list should now look similar to: Figure 4 - The Populated "Master Numbers" List Add the Auto-Number Field to the Document Library If you have an existing document library you can use that or you can use the process shown in 1.1 above to create a new one. Add the Auto-number Field to the Document Library For our example we are going to create a new field called “Item #” that will be used to number the documents within the library. 1. Click the “Library” tab. 2. Click the “Library Settings” button. 3. Click the “Create Column” link. 4. Set the Column Name to “Item #.” 5. Set the Column Type to “Single line of text” (similar to Figure 5): Figure 5 - The "Name and Type" Area We are now ready to create our workflow. How Do I… Create an Auto-Number using Nintex Workflow 4 V1.2/0417 © WSP USA, 2017 HOW DO I… A Quick Lesson for ProjectSolveSP Users Create the Auto-Number Workflow We will create our workflow from the document library where we just created the “Item #” field. 1. Access the Document Library. 2. Click the “Library” tab. 3. Open the “Workflow Settings” menu. 4. Click the “Create a Workflow in Nintex Workflow” link: Figure 6 - The "Create a Workflow in Nintex Workflow" Link 5. Click the “Blank” icon within the “Select a Workflow Template” screen: Figure 7 - The 'Blank" Workflow Icon 6. Click the “Create” button. 7. The Nintex Workspace will then appear for you to work in (Figure 8): How Do I… Create an Auto-Number using Nintex Workflow 5 V1.2/0417 © WSP USA, 2017 HOW DO I… A Quick Lesson for ProjectSolveSP Users Figure 8 - The Nintex Workspace Configure the Workflow We will be using the following actions to create our workflow: Get the Source Number from the Master List (“Query List” Action) Pad left the Source Number with Leading Zeros (“Set Variable” Action) Prefix the Padded Source Number with ABC_ (“Build String” Action) Set the Item # to the Prefixed Padded Source Number (“Set Field Value” Action) Increment the Source Number (“Math Operation” Action) Update the Master List with the Source Number Plus 1 (“Update Item” Action) Once these have been deployed, we should see something similar to Figure 9. How Do I… Create an Auto-Number using Nintex Workflow 6 V1.2/0417 © WSP USA, 2017 HOW DO I… A Quick Lesson for ProjectSolveSP Users Figure 9 - The Basic "Auto-Number" Workflow Note: To make this workflow easier to use, it is highly recommended that you update the names of each action (by clicking on it and renaming it) to reflect the activity it will be performing. You should now see a workflow similar to Figure 10. How Do I… Create an Auto-Number using Nintex Workflow 7 V1.2/0417 © WSP USA, 2017 HOW DO I… A Quick Lesson for ProjectSolveSP Users Figure 10 - The Renamed Basic "Auto-Number" Workflow How Do I… Create an Auto-Number using Nintex Workflow 8 V1.2/0417 © WSP USA, 2017 HOW DO I… A Quick Lesson for ProjectSolveSP Users Configure “Get the Source Number from the Master List” The first thing we need the workflow to do is grab the current number from the Master list and put it into a variable that we can work with. Figure 11 - The "Get the Source Number from the Master List" Action Create the Variable To create our new variable: 1. Double-click on the action icon to open it in configuration mode. 2. Click the “Variables” icon to access the “Variables” screen: Figure 12 - The "Workflow Variables" Selection Icon 3. Once the “Workflow Variables” screen appears, click the “New” button: Figure 13 - The "New" Workflow Variable Button 4. Set the Name to “nextNumber.” 5. Set the Type to “Number.” 6. The screen should now look similar to Figure 14. How Do I… Create an Auto-Number using Nintex Workflow 9 V1.2/0417 © WSP USA, 2017 HOW DO I… A Quick Lesson for ProjectSolveSP Users Figure 14 - The Populated "nextNumber" Variable Screen 7. Click “Save” to create this workflow variable. 8. You will be returned to the “Configure Action” screen. Configure the Action Once we have created our variable, we can configure the workflow to use that variable to store the number from the Master list in. From the Configure Action screen: 1. Set “Editor Mode” to “Query Builder.” 2. Set “List” to the “Master Numbers” List. 3. Set the “Filter” to “Select all list items.” 4. Set “Field” to “Source Number” and then click the “Add” button. 5. Set “Source Number” field to equal our new variable set above: How Do I… Create an Auto-Number using Nintex Workflow 10 V1.2/0417 © WSP USA, 2017 HOW DO I… A Quick Lesson for ProjectSolveSP Users Figure 15 - The Updated "Configure Action" Screen 6. Click “Save” to save the configuration update. Configure “Pad left the Source Number with Leading Zeros” The next thing we need to do is left pad our number so that instead of “1” or “2”, it will display as “0001” or “0002.” Figure 16 - The "Pad left the Source Number with Leading Zeros" Action Create the Variable We need to create a variable for containing the padded number for use later in the workflow. To do this, we will create a new variable called “prefixedNextNumber” and set the type to “Single line of text”, similar to Figure 17. How Do I… Create an Auto-Number using Nintex Workflow 11 V1.2/0417 © WSP USA, 2017 HOW DO I… A Quick Lesson for ProjectSolveSP Users Figure 17 - The "prefixedNextNumber" Variable Configure the Action Once we have our variable, we can configure our action to utilize it. 1. Under “Set” select the variable we just created. 2. Set “Equals” to “Value.” 3. Click the “Insert Reference” button: Figure 18 - The "Insert Reference" Button 4.
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages25 Page
-
File Size-