You need to sign in to do that
Don't have an account?
JJSHHS
Trigger the object validation rules
Hi, I have a couple of questions..
1) I have a validation rule setup on the Phone field of the Acct object - that it should be it at least 10 digits. When I'm using a custom controller and have multiple pages to navigate (the second page is to collect contact info), the validation rule isn't fired till I tried to save at the end of the wizard. Is there anyway to fire validation rules before I move to the next page?
2) On the second page, I'm trying to add multiple contacts for a single acct. How do I enforce that I should not be allowed to add more than 5 contacts for a given time. Should I use Javascript or is there way in VF, I can accomplish this...
Please advise.
1) I have a validation rule setup on the Phone field of the Acct object - that it should be it at least 10 digits. When I'm using a custom controller and have multiple pages to navigate (the second page is to collect contact info), the validation rule isn't fired till I tried to save at the end of the wizard. Is there anyway to fire validation rules before I move to the next page?
2) On the second page, I'm trying to add multiple contacts for a single acct. How do I enforce that I should not be allowed to add more than 5 contacts for a given time. Should I use Javascript or is there way in VF, I can accomplish this...
Please advise.
Regarding #1, is there any way you could input validations using VF itself without Javascript.
Regarding#2, I'm not using Javascript. i'm using VF to capture the contacts (using some predefined fields)
I'm confused as to how you don't know the number of contacts. If you have it via VF then you should know how many contact informations you have on the page. Can you include some code to show what you are doing?