What is JotForm?
JotForm is a free online form builder which helps you create online forms without writing a single line of code. No sign-up required.

At JotForm, we want to make sure that you’re getting the online form builder help that you need. Our friendly customer support team is available 24/7.

We believe that if one user has a question, there could be more users who may have the same question. This is why many of our support forum threads are public and available to be searched and viewed. If you’d like help immediately, feel free to search for a similar question, or submit your question or concern.


  • Profile Image

    How to integrate calculations to my form. Add stock limit option.

    Asked by ExcursieNGV on January 03, 2014 at 11:00 AM

    Hi,

    i am using  forms as a way to subscribe to excursions (events) with a maximum number of participants. Each submission may contain one or more (4-5) participants. I am looking for a way to close the form when the maximum number of participants is reached (which is not equal to the number of submissions). Or a way to display how many participants are already registered. Can you help?

     

    Tnx

    Ben

    calculations integrate Submissions style maximum subscribe
  • Profile Image
    JotForm Support

    Answered by KadeJM on January 03, 2014 at 12:23 PM

    Hi Ben, It is possible to use Calculations on your form in two ways. The First being that we have a Calculate Field feature using basic calculations and then the Second being to embed a custom scripted caculation overhaul into the form's source code as a workaround to do things that are much more advanced. It honestly really mostly depends on what exactly you are trying to do with the calculations.

    If I'm understanding it all correctly in example:

    FORM A = 10 Partipants Limit (max)

    - First Submission for FORM A = Contains 5 Participants registered inside it

    - Second Submission for FORM A = Contains 3 Participants registered inside it

    - Third Submission for FORM A = Contains 2 Participants registered inside it

    *So now FORM A (in example above) has reached its MAX Participant Limitation of 10 and closes.*

    Is that kind of what you are trying to do with it?

     

    I know we have a seating reservation app but I don't really think that it's suited for something of this sort . And I thought we had something else that might work for this but either I don't remember the name of it or we don't have it. I will see what I can figure out more for this ability but I would like confirmation and your input before I continue with it this way we know better about what exactly you want with it.

  • Profile Image

    Answered by ExcursieNGV on January 03, 2014 at 02:39 PM

    Hi KadeJM,

     

    thx for the quick answer.

     

    Your example is exactly what i am searching for. In your example I will have 3 submissions and 10 participants and will close.

    Its even ok when I am able to show that the maximum is reached whitout automatic closing the form.

    Btw, your numbers are close to reality, i have a maximum of 20 -25 participants and expect around 15 submissions. I will close at 25 submissions to be sure that there is not an overload. I have 10 events a year.

    Thx again,

     

    Ben

  • Profile Image
    JotForm Support

    Answered by Mike_T on January 03, 2014 at 04:10 PM

    Unfortunately, we do not have a stock limit option available on forms. I have submitted an additional feature request to our Development Team, and hope that we will see that option added at some point in the future.

    You might consider trying the following workaround:

    1. Integrate a form with a Google Spreadsheet service.

    2. Add a cell with SUM function to calculate the total:

    3. Publish to the web mentioned cell:

    4. Embed that cell into your form (Text HTML field):

    Example:

    http://form.jotformeu.com/form/40025613545345

    Note, it seems that the number is being updated with some delay due to publishing delay from the Google Spreadsheet. You can submit the form, wait several minutes and refresh the page.