procedure tmypanel.wmmouseleave(var message: tmessage);
begin
//确定鼠标进入中是否有代码,如果有执行
if assigned(fonmouseleave) then
fonmouseleave(self);
end;
end.
u 然后点击【component】->【install component…】,如下图:

在“unit file name”中选中我们刚才的单元mypanelunit.pas,其他选项默认。然后点击“ok”, 在“package dclusr.bpk will be build then install, continue?”选择“yes”,待编译安装完后保存,这样tmypanel控件就被安装到delphi中了。滚动delphi的控件面板到最后,将会看到如下图的控件页mycontrol:
