Mediv Posted August 21, 2012 Posted August 21, 2012 Hi Farhad. Very interesting situation. Took your demo example with fish, added the button (Click) and my form, grid tied with ClientDataSet. In the form of context-sensitive search is implemented, the OnKeyDown event on the component TUniEdit put filters on ClientDataSet. The sequence of actions for which the focus is lost from the component TUniEdit: 1. I type in the box for example "sna", filtered 3 records. All is well. 2. Box is cleared, a complete list. all is well. 3. I type "sn", filtered multiple entries, do click on the grid, and then put the cursor in the TUniEdit and add character "a", is filtered out 3 records, but the focus away from the component! continue to type the text in the box does not work, you need to constantly move the cursor to TUniEdit!!!!!!!! FishFactsTest.zip Quote
Ronak Posted August 28, 2012 Posted August 28, 2012 Hi, The issue starts when once the grid gets focused, the workaround I found is : procedure TUniForm1.UniEditAjaxEvent(Sender: TComponent; EventName: string; Params: TStrings); begin UniEdit.SetFocus; end; procedure TUniForm1.Grid1AjaxEvent(Sender: TComponent; EventName: string; Params: TStrings); begin UniEdit.SetFocus; end; with this, UniEdit always remains focused.. Regards Quote
Mediv Posted August 28, 2012 Author Posted August 28, 2012 Hi, The issue starts when once the grid gets focused, the workaround I found is : procedure TUniForm1.UniEditAjaxEvent(Sender: TComponent; EventName: string; Params: TStrings); begin UniEdit.SetFocus; end; procedure TUniForm1.Grid1AjaxEvent(Sender: TComponent; EventName: string; Params: TStrings); begin UniEdit.SetFocus; end; with this, UniEdit always remains focused.. Regards Thanks, helped. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.