﻿function ReturnValidate() {
     if (document.MM_returnValue == true) {
        url = document.location;
        document.aspnetForm.action = url;
        document.aspnetForm.submit();
    }
}
function backToNormal(veld){
    veld.style.backgroundColor = "white";
}

/* Menu maken */
var timer;
var curId;
var startPosition;

function activateSubMenu(id, volgNr){
    if (curId != null){
        if(id != curId){
           veld = document.getElementById(curId);
           veld.style.display = "none";
        }
    }
    veld = document.getElementById(id);
    
    if(startPosition == null){
        startPosition = veld.style.marginLeft;
    }
    var browserName=navigator.appName; 
     var fromLeft;
    if (browserName=="Netscape")
    { 
        fromLeft = 0;
    }
    else 
    { 
     if (browserName=="Microsoft Internet Explorer")
     {
        fromLeft = 393;
     }
     else
      {
        fromLeft = 0
       }
    }
//  veld.style.marginLeft = (78 * volgNr) + startPosition - fromLeft  + "px";
    veld.style.display = "block";
    curId = id;
}
function deactiveSubMenu(id){
    timer = setTimeout("deactivateNow('"+id+"')",500);
}
function deactivateNow(id){
    veld = document.getElementById(id);
    veld.style.display = "none";
}
function stopTimer(){
    clearTimeout(timer)
}
function startTimer(id){
    timer = setTimeout("deactivateNow('"+id+"')",500);
}
