FOutputDate is the first date of the month and EOutputDate is the last day of month. When this error message shows up, " Error(Text000, FOutputDate, EOutputDate, day2); " the "day2" variable has the value 0
dataitem("Customized Calendar Change"; "Customized Calendar Change")
{
trigger OnAfterGetRecord()
var
CCC: Record "Customized Calendar Change";
begin
CCC.SetRange(Date, FOutputDate, EOutputDate);
if CCC.FindSet() then begin
if CCC.Nonworking = false then begin
day2 := ccc.Count;
end;
end;
end;
}