Page 1 of 1
Forum

Welcome to the Tweaking4All community forums!
When participating, please keep the Forum Rules in mind!

Topics for particular software or systems: Start your topic link with the name of the application or system.
For example “MacOS X – Your question“, or “MS Word – Your Tip or Trick“.

Please note that switching to another language when reading a post will not bring you to the same post, in Dutch, as there is no translation for that post!



Share:
Notifications
Clear all

[Solved] Lazarus - TComboBox not closing up

1 Posts
1 Users
0 Reactions
1,433 Views
 Hans
(@hans)
Famed Member Admin
Joined: 12 years ago
Posts: 2859
Topic starter  

Just a small issue I ran into while developing an application: A TComboBox that did not closeup properly.

In my particular case, the TComboBox was located on a TTabSheet (of a TPageControl). Based on the users selection another TTabSheet would be shown effectively hiding the one that was holding the TComboBox. This resulted in the combobox dropdown remaining visible, even though the combobox itself was no longer visible.

It took me a while to find a solution, which proved rather simple: Change the active focus to another component.

...
  // handle reading the selected item and such here
...
  AnotherComponent.SetFocus;
  Application.ProcessMessages;
...

   
ReplyQuote
Share: