0

I have a field called "Bulletin#" in my InfoPath form that increments on submit based off of the OOTB SharePoint column "ID".

The rule on clicking "submit" is to check to see if the field "Bulletin#" is empty; if not set the value to max(ID)+1. I have setup a receive connection to query ID.

I followed the same approach; created a receive connection to query Bulletin# (with the library sorted according to ascending ID, so it would get the last Bulletin# used) and use max(Bulletin#)+1. But I end up getting this:

enter image description here enter image description here

Is there a workaround or another approach to it?

Thanks

2
  • What is max(Form#) returning? NaN is "Not A Number" May 15, 2012 at 20:48
  • @rjcup3 yes max(form#) returns nan, although I have set up the field with a integer data type. But max(ID) returns an integer.
    – user7400
    May 16, 2012 at 0:26

2 Answers 2

0

When I was selecting the field from the insert field wizard, I was selecting from under the query fields. When I selected from the data fields it worked just fine. enter image description here

-1

max(field) + 1

doesn't always work... if the form is opened in edit mode it increments again.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.