procedure %TYPE%.HandleEvent;
begin
{$IFDEF VER70}
  inherited HandleEvent(Event);
{$ELSE}
  TDialog.HandleEvent(Event);
{$ENDIF}
  if Event.What and evMessage <> 0 then
     begin
       case Event.Command of

       else Exit;
       end;
       ClearEvent(Event);
     end;
end;