EhLib.Com
https://forum.ehlib.com/en/

Problem with Grid Search with Mask in DataSet.
https://forum.ehlib.com/en/viewtopic.php?f=5&t=1039
Page 1 of 1

Author:  Luciano_F [ 22 Apr 2020, 14:26 ]
Post subject:  Problem with Grid Search with Mask in DataSet.

Hello good day.

1º I am trying to perform a high value field search but due to the Mascara in the Dataset I cannot search the type of mask is
'R$ ,0.00; R$ -,0.00' thus a value like
1450,15 will be equal to R$ 1.450,15 this value I can't search by typing directly into the Grid with the option "splCellInplaceEh"

2º Another thing if at the same time that I am doing the search, I Click on any column other than the Column I am typing will give error.

3º In TDbcomboboxEh for me to be able to simulate "csDropDownList" I need to fill in the "KeyItems" property and activate the "LimitTextToListValues" property but that way I can't do partial searches like typing "Mourao" and finding "Campo Mourao" I have to disable the "LimitTextToListValues" property, but I would like to simulate "csDropDownList" so as not to let the user type something that does not exist in combobox and use "lsftContainsEh".

Attached a Project and a Video explaining the problems.
https://mega.nz/file/Em5F1ajQ#F3fFFCqpc8EQHjnyEv3LjqXkIpJLLxG2Fyz9CpdIFdk

Author:  EhLibSupport [ 27 Apr 2020, 18:46 ]
Post subject:  Re: Problem with Grid Search with Mask in DataSet.

Hello good day.

Quote:
1º I am trying to perform a high value field search but due to the Mascara in the Dataset I cannot search the type of mask is
'R$ ,0.00; R$ -,0.00' thus a value like
1450,15 will be equal to R$ 1.450,15 this value I can't search by typing directly into the Grid with the option "splCellInplaceEh"

Can you describe how you think the search should work here?
On the screen there is a DisplayText 'R$ 1.450.15' and there is an EditText value of '1450.15'.
The user presses 1, then 4.

If we use DisplayText (R $ 1.450,15) we cannot find text '14' because the point interferes.

If we use EditText (1450.15) we will find the text, but we will not be able to highlight the found text '14' since it is not on the screen. The user will not understand the state of the search, as he will not see th highlighted text on the screen.

Quote:
2º Another thing if at the same time that I am doing the search, I Click on any column other than the Column I am typing will give error.

We will write a little later on this issue.
Perhaps it can be solved.

Quote:
3º In TDbcomboboxEh for me to be able to simulate "csDropDownList" I need to fill in the "KeyItems" property and activate the "LimitTextToListValues" property but that way I can't do partial searches like typing "Mourao" and finding "Campo Mourao" I have to disable the "LimitTextToListValues" property, but I would like to simulate "csDropDownList" so as not to let the user type something that does not exist in combobox and use "lsftContainsEh".

There is no such possibility now.
We suggest writing an event when focus is lost TDbcomboboxEh
in which to write a message that the text should correspond to the list.

The event may look as follows.
Code:
procedure TForm2.DBComboBoxEh1Exit(Sender: TObject);
begin
  if (DBComboBoxEh1.Text <> '') and
     (DBComboBoxEh1.ItemIndex = -1) then
  begin
    ShowMessage('Please Enter value from list');
    DBComboBoxEh1.SetFocus;
  end;
end;

Author:  Luciano_F [ 27 Apr 2020, 20:09 ]
Post subject:  Re: Problem with Grid Search with Mask in DataSet.

Quote:
Can you describe how you think the search should work here?
On the screen there is a DisplayText 'R$ 1.450.15' and there is an EditText value of '1450.15'.
The user presses 1, then 4.
If we use DisplayText (R $ 1.450,15) we cannot find text '14' because the point interferes.
If we use EditText (1450.15) we will find the text, but we will not be able to highlight the found text '14' since it is not on the screen. The user will not understand the state of the search, as he will not see th highlighted text on the screen.

I would like the Client to write "1 the point 4" and the search would find.
However, the research cannot find the point because it only exists in the mask.


Quote:
There is no such possibility now.
We suggest writing an event when focus is lost TDbcomboboxEh
in which to write a message that the text should correspond to the list.
The event may look as follows.

This event is not interesting because the "TDbComboboxEh" does not have a "csDropDownList" Style, that is, I need the "TDbComboboxEh" to be locked for typing something that does not exist in the list because this is a requirement of a client of mine.
I prefer to wait for a native component solution for this problem.

Author:  EhLibSupport [ 28 Apr 2020, 02:58 ]
Post subject:  Re: Problem with Grid Search with Mask in DataSet.

Quote:
I would like the Client to write "1 the point 4" and the search would find.
However, the research cannot find the point because it only exists in the mask.

I did not correctly understand your question at the beginning.
Yes, grid doesn't allow to type '.'. It replace it with DecimalSeparator.
We will fix it at the next build.

Author:  danieldavila [ 28 Apr 2020, 14:07 ]
Post subject:  Re: Problem with Grid Search with Mask in DataSet.

I think the "Client" he refers to would be the User typing the values: 1,405.56

Author:  Luciano_F [ 12 May 2020, 14:36 ]
Post subject:  Re: Problem with Grid Search with Mask in DataSet.

Hello good morning any position on the items listed above?

Thankful.

Author:  EhLibSupport [ 12 May 2020, 17:04 ]
Post subject:  Re: Problem with Grid Search with Mask in DataSet.

Hello

We fixed - 1º in EhLib.VCL 9.5 Build 9.5.014
2º 3º So far, no change.

Author:  Luciano_F [ 12 May 2020, 17:41 ]
Post subject:  Re: Problem with Grid Search with Mask in DataSet.

I will wait for the correction of 2 and 3 before I can update.

Thankful.

Author:  Luciano_F [ 05 Jun 2020, 18:21 ]
Post subject:  Re: Problem with Grid Search with Mask in DataSet.

Hello, some position on the above corrections.

Page 1 of 1 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/