<!DOCTYPE html>
<html>
<head>
</head>
<body>
<table>
<tr>
<td><b>BankName</b></td>
<td><b>BIC</b></td>
</tr>
<tr>
<td>Bank1</td>
<td>Adress1</td>
</tr>
<tr>
<td>Bank2</td>
<td>Adress2</td>
</tr>
</table>
Bank Name: <br />
<textarea id='bank' cols=56 rows=6></textarea></form>
<br />
Bank Adress: <br />
<textarea id='bic' cols=56 rows=6></textarea></form>
<script>
textarea1 = document.getElementById('bank');
textarea2 = document.getElementById('bic');
table=document.querySelector("table")
trs=table.querySelectorAll("tr")
f=function(){
var data=this.querySelectorAll("td")
textarea1.value+=data[0].innerHTML+"\n"
textarea2.value+=data[1].innerHTML+"\n"
}
for(var i=1; i<trs.length; i++){
trs[i].ondblclick=f
}
</script>
</body>
</html>