Jump to content
  • 0

Hault Auto Submit code on Details page


DesiLogi

Question

I have a Details page that I'm using Auto Submit code to cycle through and update related records. However, when it gets to the last record (for example, 4 of 4) it keeps in the 'submit' cycle. I need the form to stop submitting once it's submitted the last record. Then, ideally, I need the form to go to another web page.  But getting it to stop submitting after the last record update would be a good first step. Does anyone know how to adjust the Auto Submit code I'm using below?

<script type="text/javascript">

  if(document.getElementById("caspioform")) {

  document.getElementById("caspioform").style.display = 'none';

  setTimeout('document.forms["caspioform"].submit()',1000); }

</script>

 

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

  • 0

I figured out a workaround, if anyone needs a similar solution. A filtered View is used for the data source. 

This enables the auto-submit to run and when there are no more records to update (because the View filters out updated records) I use the Localization to redirect to a new url when there are no records (351 message). 

So basically, all the records in the recordset get cycled through on the Details datapage (set to go to 'Next Record' after update) and then when there are no further records (because the View datasource is empty) it redirects to a new url. 

A bit of a labyrinthine process but it gets the job done. 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...