Is there a way in Delphi to disallow the form to focus on any of its components but not disabling those components? I tried Self.SetFocus
on FormActivate
event of the form but the program says that it cannot focus on a disabled component.
Use the following OnActivate
event handler:
procedure TForm1.FormActivate(Sender: TObject);
begin
ActiveControl:= nil;
end;
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With