Kentico 11. Save bizform record, then on submit again, create a new record (not update first one)

Tom Wisneski asked on April 3, 2020 18:06

Question. A calculator using a Bizform submit, so it saves the values. The user should have the option to calculate and calculate again - with new values in the input fields. That portion works fine. However, in the saving of the record for each submit - it is updating the first record created. If however you come back the page 'fresh', then new record is saved rather than updating or overwriting the initial entry (which is how it should be each time a user clicks calculate / submit). I should not have to redirect or go to a different page upon submit. Is there a way to have the records save without coming to the page fresh? Thanks.

Recent Answers


Dmitry Bastron answered on April 3, 2020 18:31 (last edited on April 3, 2020 18:32)

Hi Tom,

Do you use Kentico online Form widget (via Form builder)? Or do you use your custom widget with creating a BizInfo in the custom code?

If that's Kentico form, what is configured in "After the form is submitted" setting? And how do you do "submit" and "recalculate" if the standard form widget has only one submit button?

0 votesVote for this answer Mark as a Correct answer

Tom Wisneski answered on April 3, 2020 18:58

Dmitry...it is a custom webpart with the calculations being done on the code behind (ascx.cs) file (webforms). The calculations are using values stored in a custom table, which calculate against the user input data fields. It is a temperature & altitude for fuel interpolation calculator.

0 votesVote for this answer Mark as a Correct answer

Dmitry Bastron answered on April 6, 2020 09:56

How do you clear the form on re-calculate click? It is likely that form submission ID is stays the same in one of your hidden fields, that's why it is overriding the row with the same ID. As it is quite hard to help in this case without seeing your custom code, if you can share the code of your web part I can be more specific then.

0 votesVote for this answer Mark as a Correct answer

Brenden Kehren answered on April 15, 2020 16:18

I'm not sure why you're using a biz form for your calculator. Your "calculator" should be custom code, then if you want them to sign up or submit their info before or after using the calculator, you have that be a biz form independent of the calculator. Don't try to make them do one in the same as they are different activities.

If your calculator is posting the page back and submitting the biz form, then wrap the calculator in an update panel and this should resolve the issue.

0 votesVote for this answer Mark as a Correct answer

Tom Wisneski answered on April 15, 2020 16:23 (last edited on April 15, 2020 16:24)

Brenden. We had forgo the "submit to it's self" idea. I works fine like this. The reason for the bizform usage since it has much built in. It works fine; Thanks.

1 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.