Many, many thanks for your reply.
Yes, I did copy the script into the footer, but it does not work.
So I would like to find out what I am doing wrong.
I have two fields Firstname and Lastname in my table called Students.
I also added a field called Name to that table.
I created a Web Form to capture submissions. I modified the script
to include Firstname and Lastname to populate the third field called Name.
I pasted this script inside the HTML footer:
function concatenate()
{
//(1) Retrieve the value of the field Firstname and store in a variable firstname.
var firstname = document.forms [0].InsertRecordFirstname.value;
//(2) Retrieve the value of the field Lastname and store in a variable lastname.
var lastname = document.forms[0].InsertRecordLastname.value;
//(3) Create the string and define a variable with that value.
var name = firstname+lastname;
//(6) Post the string to the targeted field.
document.getElementById(\"InsertRecordName\").name;
}
//(5) On submitting the webform, the function calculate is executed.
document.forms[0].onsubmit=concatenate;