use calculate to pre-fill a field
Hi
I have a form where I want to pre-fill the e-mail field based on firstname and lastname fields. I have this script in the email field:
var fornavn = this.getField("Fornavn").valueAsString;
var etternavn = this.getField("Etternavn").valueAsString;
fornavn = fornavn.replace(" ","");
etternavn = etternavn.replace(" ","");
event.value = fornavn + "." + etternavn + "@company.com";
But how can I allow the user of the form to override this and enter their own email address if they don't want to have the one suggested by the script?
