        var str_coaListPanel,str_loonsyntehesePanel,str_coaListPanel_sub,str_loonsyntehesePanel_sub;
        
        function hideTip() 
        {
	      //document.getElementById("ToolTipBox").style.display='none'; 
	        document.getElementById("ToolTipBox").style.visibility = "hidden";
	    }
	     
	    function showTip(e,strToolTip) 
        {
            var ToolTipBox = document.getElementById("ToolTipBox");
            if (ToolTipBox  != null) 
            {
                //ToolTipBox.innerText = strToolTip;                // IE
                //ToolTipBox.textContent = strToolTip;            // FireFox
                ToolTipBox.innerHTML = strToolTip;
                
                // Variabelen
                var newXpos = 0;
                var newYpos = 0;
                var winHeight = 0;
                var winWidth = 0;
                var scroll = getScroll(); 
                  
                //         
                // Finding the size of the browser window ( venster is verklein/vergrootbaar )
                //
                if( typeof( window.innerWidth ) == 'number' ) 
                { //Non-IE
                    winWidth = window.innerWidth;
                    winHeight = window.innerHeight;
                } 
                else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) 
                { //IE 6+
                    winWidth = document.documentElement.clientWidth;
                    winHeight = document.documentElement.clientHeight;
                }       
                else
                { //Others
                    winWidth = document.height ? document.height : document.documentElement.offsetHeight - 25;
                    winHeight = document.width ? document.width : document.documentElement.offsetWidth - 25;                
                }                      
                          
                //                
                // Decide new X-position en Y-position
                //
                if (e.clientX > (winWidth - ToolTipBox.offsetWidth))
                    newXpos = (winWidth - ToolTipBox.offsetWidth) - 200 + scroll.x;
                else
                    newXpos = e.clientX - 200 + scroll.x;
                
                if ( (e.clientY + ToolTipBox.offsetHeight) > winHeight )
                    newYpos = e.clientY - 20 - ToolTipBox.offsetHeight + scroll.y;
                else
                    newYpos = e.clientY + 20 + scroll.y;
                
                // MSIE6 Positioning Bug ; 
                //       Probleem IE : hij positioneert vanaf de parent-div.. 
                //       FF : Parent is de 'body' dus (0,0)
                if ( ToolTipBox.offsetParent != null )
                { // Reset the positions
                    if ( ToolTipBox.offsetParent.offsetLeft > 0 )                
                        newXpos = newXpos - ToolTipBox.offsetParent.offsetLeft;
                    if ( ToolTipBox.offsetParent.offsetTop > 0 )
                        newYpos = newYpos - ToolTipBox.offsetParent.offsetTop;  
                }
                
                // 
                // MSIE Z-Index ignored by selects IE Bug
                //
                if (navigator.appVersion.indexOf("MSIE") != -1)
                {
                    ifrm = document.createElement("IFRAME");
                    ifrm.style.width = (ToolTipBox.offsetWidth+2) + "px";
                    ifrm.style.height = (ToolTipBox.offsetHeight+2) + "px";
                    ToolTipBox.appendChild(ifrm);                 
                }
                
                //
                // Style aanpassen                
                //
                ToolTipBox.style.left = newXpos + "px";
                ToolTipBox.style.top = newYpos + "px";
                // Omwille van gebruik van ToolTipBox.offsetWidth & ToolTipBox.offsetHeight gebruik maken van visibility en niet van display none-block
                ToolTipBox.style.visibility = "visible"; //ToolTipBox.style.display = 'block'; 
            } 
        }
        
        // returns the scroll left and top for the browser viewport.
        function getScroll() {
           if (document.body.scrollTop != undefined) {	// IE model
              var ieBox = document.compatMode != "CSS1Compat";
              var cont = ieBox ? document.body : document.documentElement;
              return {x : cont.scrollLeft, y : cont.scrollTop};
           }
           else {
              return {x : window.pageXOffset, y : window.pageYOffset};
           }
        }
        
        function ShowProcessing(strMessage)
        {
            var ProcessingBox = document.getElementById("div_processing");
            var LoonsynthesePanel =  document.getElementById(str_loonsyntehesePanel);
            var LoonsynthesePanel_sub =  document.getElementById(str_loonsyntehesePanel_sub);
            var CoaPanel =  document.getElementById(str_coaListPanel ); 
            var CoaPanel_sub =  document.getElementById(str_coaListPanel_sub);  
            
            if (LoonsynthesePanel_sub  != null)
                LoonsynthesePanel_sub.style.display='none';   
            if (LoonsynthesePanel  != null) 
                LoonsynthesePanel.style.display='none'; 
            if (CoaPanel_sub != null)  
                CoaPanel_sub.style.display='none';   
            if (CoaPanel != null)
                CoaPanel.style.display='none';  

            if (ProcessingBox  != null)
           {  
                ProcessingBox.innerText = strMessage;                // IE
                ProcessingBox.textContent = strMessage;            // FireFox 
                ProcessingBox.style.display='block';  
            } 
        }
       
        function showFirstMatchingListItem(strdll, strtxt)
        {
            var obj_dropdownlist =  document.getElementById(strdll);
            var obj_filter = document.getElementById(strtxt);
            var intStartIndex = 0;
            var strValue = "", strValueToSearchFor = ""; 
            
            if ((obj_dropdownlist != null) && (obj_filter != null))
            {
                strValueToSearchFor = obj_filter.value;
                if (strValueToSearchFor == '')
                { 
                    obj_dropdownlist.value = "-1";
                    return; 
                }
                    
                for (var intCounter = 0; intCounter < obj_dropdownlist.length; intCounter++)
                {
                    
                    if (isNaN(strValueToSearchFor))
                    {
                        intStartIndex = obj_dropdownlist[intCounter].text.indexOf('-',0) + 2;  // zoeken op Omschrijving 
                        strValue = obj_dropdownlist[intCounter].text.substr(intStartIndex,strValueToSearchFor.length);
                    }
                    else
                        strValue = obj_dropdownlist[intCounter].value.substr(0,strValueToSearchFor.length);
                    
                    if (strValue.toUpperCase() == strValueToSearchFor.toUpperCase())
                    {
                        obj_dropdownlist.value = obj_dropdownlist[intCounter].value;
                        return;
                    }
                } 
               obj_dropdownlist.value =  "-1";
            }  
        }
        
        function MC_Range_Validator(txtBox, min, max, msg){
            //alert(document.all.item(txtBox).value);
            if(parseFloat(document.all.item(txtBox).value) >= parseFloat(max)){
                alert("" + msg + "");
            }
        }
        
        function checkEchtgenoot(chkEchtVa, chkEchtInval, ddl_BurgStaat){
            //Als we een burgelijke staat selecteren waarin we over geen echtgenoot beschikken worden de
            //checkboxen van de echtgenoot gedisabled            
            document.getElementById(chkEchtVa).disabled = (document.getElementById(ddl_BurgStaat).value != 2 && document.getElementById(ddl_BurgStaat).value != 7);
            document.getElementById(chkEchtInval).disabled = (document.getElementById(ddl_BurgStaat).value != 2 && document.getElementById(ddl_BurgStaat).value != 7);
        }
        
        function unCheckBoxVa(chkEchtVa, chkEchtInval){
            document.getElementById(chkEchtInval).checked = false;
        }
        
        function unCheckBoxInval(chkEchtVa, chkEchtInval){
            document.getElementById(chkEchtVa).checked = false;
        }
       
        function HideShowOrToggleDiv(divId, action)
        {
            var div = $("#" + divId);
            if(div.length > 0)
            {
                if(action == "HIDE")
                {
                    div.hide('slow');
                }else if(action == "SHOW")
                {
                    div.show('slow');
                }else if(action == "TOGGLE")
                {
                    div.toggle(400);
                }
            }
        }       
       
        function OpenColumbusDocument()
        {
            var width = 600;
            var height= 700;
            var left = (screen.width/2)-(width/2);
            var top = (screen.height/2)-(height/2);
            window.open('/be/advice/Public/ColumbusDocumentPopUp.aspx', 'ColumbusDW' , 'toolbar=no,location=no,status=no,menubar=no,scrollbars=no,resizable=yes,width='+width+',height='+height+',top='+top+',left='+left);
        } 
