Jump to content

Match Values


Recommended Posts

Is there a way on an update details page to put a script that will compare two different fields and ensure they match each other? If they do not match, to give an error and not allow the submission?

I know that Caspio provides this for one field, but I want to compare two different fields...

Thanks,

Mark

Link to comment
Share on other sites

This is possible using Java Script on the DataPage which check for the value of the fields and if they do not meet the condition, return false on submission.

There are some sample scripts at viewforum.php?f=14 which give you an idea how to integrate Java Script within a Caspio form.

To reach Caspio team to write the code please contact them at http://www.caspio.com/services/custom-a ... opment.asp.

Best,

Bahar M

Link to comment
Share on other sites

Well I have this put together so far, but it doesn’t work...

If anyone out there has any recommendations (if this is close), otherwise, Ill contact the above link for programming.

Thanks, Mark...

document.getElementById(“caspioformâ€).onsubmit=return checkCouponCodeval(“CouponCodeâ€,“couponcoderepeatâ€);

Link to comment
Share on other sites

When calling a Caspio element you should use EditRecordFIELDNAME if it is on details page, for example if your field name is CouponCode then call it as:

document.getElementById(“EditRecordCouponCode”).value;

Also when you call the function call it like (remove return):

document.getElementById(“caspioform”).onsubmit= checkCouponCodeval(“CouponCode”,“couponcoderepeat”);

Hope this helps.

Best,

Bahar M.

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
Reply to this topic...

×   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...