﻿// JScript File

    // exit the lms
    function exit_lms(){
        if ( confirm(g_areyousure)== 1) window.close();
    }
    
    function print_page(){
        window.print();
    }
    
    function system_properties(){
        //alert('system properties');
        var oManager = GetRadWindowManager();
        //Show a particular existing window
        oManager.open (null,"rw_properties");
    }
    
    function edit_page(){
        //debugger;
        //alert('edit this page');
        var page_name = '';
        var URL = unescape(location.href)	// get current URL in plain ASCII
	    var xstart = URL.lastIndexOf("/") + 1
	    var xend = URL.length
	    var hereName = URL.substring(xstart,xend)
	    var herePath = URL.substring(0,xstart)

	    document.write("The name of the current file is: " + hereName)
	    document.write("The path of the current file is: " + herePath)
    }
    
    function refresh_page(){
        //alert('refresh this page');
        var sURL = unescape(window.location.pathname);
        window.location.href = sURL;
    }
    
    function isNumberKey(evt)
    {
        //debugger;
        
        var charCode = (evt.which) ? evt.which : event.keyCode
        if (charCode == 46)
            return true;
        if (charCode > 31 && (charCode < 48 || charCode > 57))
            return false;

        return true;
    }

    function ValidateCheckBox(target, args) {
        var chk = document.getElementById('pan_special_reqs.FindControl(target) as CheckBox).ClientID %>');
        if (!chk.checked) {
            args.IsValid = false;
        }
        else {
            args.IsValid = true;
        }
    }
