I have 3 text boxes here. and 3rd one is updating by other two text boxes. Like wise you can intergrate it to your requirement
HTML
Fisrt name:-<input type="text" id="first" ></input>
Last Name:-<input type="text" id="last" onkeyUp="copyText()" ></input>
Full Name:-<input type="text" id="full" ></input>
JS
function copyText() {
first = document.getElementById("first");
last = document.getElementById("last");
full = document.getElementById("full");
full.value = first.value + ' ' + last.value;
}