Skip to main content
Nintex Community Menu Bar
Solved

Nintex Forms - Getting the ID from a New Item on a List

  • July 24, 2020
  • 5 replies
  • 757 views
  • Translate

AMC1ST

When a new items is submitted on Forms, I need to create a consecutive number as part of the new request code. I'm trying to use the ID number but that number ID is generated after form is submitted. How can I grab that ID number and included as part as a string that I'm using as part of my code? I'm really new with Nintex and still learning Share Point I can't figure out this one. 

Here is the formula that I have on the column but is not getting the "(ID)" number:

=CONCATENATE(SHCCODE,"-",(MID([Type of AR],1,FIND(" -",[Type of AR],1)-1)),"-",(YEAR(Created)),"-",(ID))

Here is the response: HSC-NB-2020-    (Missing the consecutive ID number)

Best answer by allan

You will not be able to get the ID before submitting your form, simply because the ID does not exist yet.
Imagine having several users posting the form they have open for 10 minutes at the same time, you will not be able to know which number is generated.
With your formula you will have the ID once the form is saved a second time. Otherwise you will need to use a workflow to calculate this number at the creation.
View original
Did this topic help you find an answer to your question?

5 replies

allan
Forum|alt.badge.img+9
  • Rookie
  • 177 replies
  • Answer
  • July 27, 2020
You will not be able to get the ID before submitting your form, simply because the ID does not exist yet.
Imagine having several users posting the form they have open for 10 minutes at the same time, you will not be able to know which number is generated.
With your formula you will have the ID once the form is saved a second time. Otherwise you will need to use a workflow to calculate this number at the creation.
Translate

AMC1ST
  • Author
  • 1 reply
  • July 29, 2020

Allan,

Thanks for your response! Totally make sense... I found a solution on a SharePoint block and is to create a new column to duplicate the ID and also create a Flow on SP Designer that will copy the ID as soon as new Item is created and works fine for me. I guess that is another approach.

But your response help me to understand that was not an error on my formula is just the logic that the ID does not exist until item is submitted.

Thanks again!

 

Translate

Forum|alt.badge.img+3

@allan Could you explain how this workflow can be created to have the ID at the time of creation ?

 

Translate

allan
Forum|alt.badge.img+9
  • Rookie
  • 177 replies
  • August 10, 2023

@nikitapatel Since it’s a workflow on SharePoint, when an item is created, an ID gets attributed. It doesn’t matter if it’s via a Nintex workflow, a SharePoint Designer workflow or manually.
When you first submit a Nintex Form, the item is created, you will the be able to retrieve the ID at the very start of your workflow (with a Set Variable action, for example), or you’ll also be able to use the ID property in the form if the user modifies the item by opening the form.

Translate

Forum|alt.badge.img+3

@allan

If I wanted to redirect the form into edit mode right after the user submits, that wouldn’t be possible right? Because the ID wouldn’t be set right away? 

I have tried doing this by using the Edit Mode URL of the form and updating the redirect link within the submit button using the ID item property at the end of the URL. However, it ends up as ID=

It ends ups as ID blank.

 

Translate

Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie Settings