TDBEdit with button lazarus / 31-LCL ---------------------------------------------------------------------- bpranoto · 2016-02-08 15:36 Is there a DBEdit component with a button? Pressing the button triggers an event which can be anything up to the programmer like displaying Customer list to choose, a calendar, anything. I have searched this forum and found http://forum.lazarus.freepascal.o rg/index.php/topic,26813.msg166397.html#msg166397. The description of the proposed TDBEditButton is exactly what I need. Unfortunately, I can't find it at the Rx packages downloaded from the svn Thanks. ---------------------------------------------------------------------- balazsszekely · 2016-02-08 15:48 Did you mean TDBEdit with an ellipsis button? If I remember correctly IBObjects supports this feature, but it shouldn't be to difficult to implement. Create a new component(TPanel + TDBEdit + TButton), then implement then appropriate events. ---------------------------------------------------------------------- LacaK · 2016-02-08 17:01 There is already TEditButton in EditBtn unit. So what we need is data-aware TEditButton (TDBEditButton which should be added into DBExtCtrls) It does not exists ATM, but it is not so big problem to create them. ---------------------------------------------------------------------- bpranoto · 2016-02-09 10:05 Okay, thanks. ---------------------------------------------------------------------- bpranoto · 2016-02-11 06:32 Thanks to GetMem, I wrote the component: TF1DBEditButton. It is a combination of a Panel, DBEdit , and BitBtn. The important properties are: 1. OnButtonClick event: do what ever you like when the user click the button 2. Glyph: to set the button glyph 3. ButtonWidth: width of the button Files attached are the component package and a small demo project. ---------------------------------------------------------------------- balazsszekely · 2016-02-11 07:42 @bpranoto Thanks for sharing your work!  I'm sure many people will find it useful. Did you test it under the following widgetsets: win32/win64/gt2/qt/carbon? ---------------------------------------------------------------------- bpranoto · 2016-02-11 08:06 not yet, I currently only use qt under linux. This simple component still needs improvements, for instance I just add DirectInput:Boolean property which can prevent the user to modify the the text content directly. Thanks for your pointer for combining the 3 components. ---------------------------------------------------------------------- balazsszekely · 2016-02-11 08:15 QuoteThis simple component still needs improvements, for instance I just add DirectInput:Boolean property which can prevent the user to modify the the text content directly.Feel free to improve it. I can test it later under win32/win64/gtk2/carbon. QuoteThanks for your pointer for combining the 3 components.You're welcome! ---------------------------------------------------------------------- bpranoto · 2016-02-11 10:05 Here is a new revision with new properties: DirectInput:Boolean, if false user cannot modify the text directly ButtonShortcut: TShortCut, enabling to invoke the button without mouse. Useful for keyboard savvy users. ---------------------------------------------------------------------- jraviles · 2018-10-11 12:51 Thanks a lot for the component, my friend, it was a brilliant idea, I incorporated it into the components I use, adding the ability to change the colors of the background and text as I enter and exit the focus, I added them to my repository:  https://bitbucket.org/redid_software/componentespub/src/master/ Thank you very much ---------------------------------------------------------------------- bpranoto · 2019-05-26 12:20 Quote from: jraviles on October 11, 2018, 02:51:21 pmThanks a lot for the component, my friend, it was a brilliant idea, I incorporated it into the components I use, adding the ability to change the colors of the background and text as I enter and exit the focus, I added them to my repository:  https://bitbucket.org/redid_software/componentespub/src/master/ Thank you very much You're welcome!