﻿// JScript File

// JScript File

// JScript File
/*

*/
var ReleasedSelectedCheckBox='';

//THIS FUNCTION WILL CALL AT PAGE ONLOAD FOR FILLING VALUES

function CallFunction()
  {
     FillSourceSites();
     ReleasedSelectedCheckBox="";
     //document.getElementById('divSourceSite').style.display="block";
  }
  CallFunction();

function FillSourceSites()
{
    var NoOfpage = eval(document.getElementById("hdnSourceSiteCurrentPageIndex").value);
    var SortColSourceSite = document.getElementById("hdnSourceSiteSortColumn").value;
    var SortOrderSourceSite = document.getElementById("hdnSourceSiteSortOrder").value;   
    
     document.getElementById("spnSourceSiteNo").innerHTML=Gallery1.ShowAlbums(NoOfpage).value;
     document.getElementById('hdnSourceSiteTotalRecord').value=Gallery1.GetTotalSourceSite().value;
    
    //if (document.getElementById("spnSourceSiteNo").innerHTML=="")
    if (document.getElementById('hdnSourceSiteTotalRecord').value==0)
     {       
        document.getElementById("spnSourceSiteNo").style.display="";
        document.getElementById("spnSourceSite").style.display="none";
        //document.getElementById("spnSourceSiteError").style.display="block";
     }
    else
     {
//        document.getElementById("spnSourceSite").style.display="block";
//        document.getElementById("spnSourceSiteError").style.display="none";        
        
        //====code for paging               
        var PageCounterMsg =Gallery1.FillBlogsCounter(document.getElementById("hdnSourceSiteCurrentPageIndex").value).value;      
        document.getElementById("spnbottommessage").innerHTML = PageCounterMsg;        
        document.getElementById("spnSourceSiteNo").style.display="";
        document.getElementById("spnPaggingSourceSite").style.display="";  
     }        
    GeneratePaggingSourceSite();
 }
	
	

