function addOption(text,value,box) {
	if(text) {
    var opt = new Option(text,value);
    var count = box.options.length;
    box.options[count] = opt;
  } else {
    alert("Du skal vælge en option, for du kan vælge retning");
  }
}

function moveOptions(from_box,to_box) {
	for(var c=(from_box.options.length - 1);c>=0;c--) {
      if(from_box.options[c].selected) {
        addOption(from_box.options[c].text,from_box.options[c].value,to_box);
        from_box.options[c] = null;
      }
    }
  }

function selectAll(box) {
    for(var c=0;c<box.options.length;c++) box.options[c].selected = true;
}


