Table of Content
HAL Forum
function Boolean DateInRange (
Date selectdate,Date startdate,Date enddate)
Description:
Defines if a date is in a period,returns true if date is in period and false if it is not.
Parameters:
selectdate selected date
startdate start date of period
enddate end date of period
external procedure InvoiceOut(record IVVc);

global
procedure InvListRn(record RcVc RepSpec)
begin
  record IVVc IVr;
  Boolean TrHs;
  
  IVr.InvDate = RepSpec.sStartDate;
  TrHs = true;
  while (LoopKey("InvDate",IVr,1,TrHs)) begin
     if (DateInRange(IVr.InvDate,RepSpec.sStartDate,RepSpec.sEndDate)==false) then begin
       TrHs = false;
     end; 
     if (TrHs==true) then begin
       InvoiceOut(IVr);
     end;
   end;
   return;
end;    
 
Related topics:
««