<?php
$StrCmd=V($_POST['TxtAc']);
//+++++
$Lot=V($_POST['Lot']);			
$Dex=V($_POST['Dex']);		
$Hax=V($_POST['Hax']);		
$EmiRuc=V($_POST['EmiRuc']);		
$EmiNom=V($_POST['EmiNom']);
$CliRuc=V($_POST['CliRuc']);
$CliNom=V($_POST['CliNom']);
//++++++++
$_SESSION['FAC_XLM_IMP_LOT']=$Lot;
$_SESSION['FAC_XLM_IMP_DEX']=$Dex;
$_SESSION['FAC_XLM_IMP_HAX']=$Hax;
$_SESSION['FAC_XLM_IMP_EMI_RUC']=$EmiRuc;
$_SESSION['FAC_XLM_IMP_EMI_NOM']=$EmiNom;
$_SESSION['FAC_XLM_IMP_CLI_RUC']=$CliRuc;
$_SESSION['FAC_XLM_IMP_CLI_NOM']=$CliNom;
//+++
if(strlen($Dex)==0)$Dex=date("d-m-Y");
if(strlen($Hax)==0)$Hax=date("d-m-Y");
//+++
$Lot_=$Lot."%";
$Dex_=ToDateEx($Dex);
$Hax_=ToDateEx($Hax);
$EmiRuc_=$EmiRuc."%";
$EmiNom_=$EmiNom."%";
$CliRuc_=$CliRuc."%";
$CliNom_=$CliNom."%";
//
$FF="id_xml>0 AND xml_nom_tmp LIKE '$Lot_' AND fec>='$Dex_' AND fec<='$Hax_' AND 
	 xml_emi_ruc LIKE '$EmiRuc_' AND xml_emi_nom LIKE '$EmiNom_' AND 
	 xml_cli_ruc LIKE '$CliRuc_' AND xml_cli_nom LIKE '$CliNom_'  ";
//++
$LStrTR=gn("count(*)","ges_xml",$FF);
$LStrPag=V($_POST['TxtPag']);
if($StrCmd=="F"){$LStrPag="1";}
$VP_RegXPag=19;	
$LStrPag=PagGet($LStrPag,$StrCmd,$LStrTR,$VP_RegXPag);
?>