for i:=0
to length(Tage)-1
do
begin
Tage[i]:=TListbox.Create(Kalender);
Tage[i].Parent:=Kalender;
SendMessage(
Handle, WM_SETREDRAW, WPARAM(False), 0);
try
Tage[i].Width:=Kalender.DefaultColWidth;
Tage[i].Height:=Kalender.DefaultRowHeight;
Tage[i].Left:=((i+Wochentag-1)
mod 7)*(Kalender.DefaultColWidth+1);
Tage[i].Top:=((i+Wochentag-1)
div 7)*(Kalender.DefaultRowHeight+1)+40;
Tage[i].Style:=lbOwnerDrawFixed;
Tage[i].Font.Size:=10;
Tage[i].Items.Add(Zentriere(inttostr(i+1)+'
.'+inttostr(m)+'
.'+inttostr(y),Tage[i].ClientWidth,Tage[i].Font));
finally
SendMessage(
Handle, WM_SETREDRAW, WPARAM(True), 0);
RedrawWindow(
Handle,
nil, 0, RDW_ERASE
or RDW_FRAME
or RDW_INVALIDATE
or RDW_ALLCHILDREN);
end;
end;