They do the same thing. In fact, in Forms.pas you will find
procedure WMClose(var Message: TWMClose); message WM_CLOSE; ... implementation ... procedure TCustomForm.WMClose(var Message: TWMClose); begin Close; end;
indicating that the WM_CLOSE message simply translates to Self.Close .
Generally, you should use Close if you can, as this is more Delphi-ish and shorter.
source share