Delphi: Can’t find the field ‘false’. Only happened to my computer

I have a TCustomClientDataSet (in memory), which is used to perform some filtering in a Delphi program.

My filtering code is as follows:

CDSFilteredGroup.Filter :='ACP_type = 1 AND ACP_by_default <> False';
CDSFilteredGroup.Filtered := True;

When I compile and run When it did, I only got the following error when I installed Delphi (XE4) on my computer:

CDSFilteredGroup: Champ'False' non trouvé.

Translation: Field’False’ not found. The same code compiles and runs perfectly on my colleague’s computer, but it is not mine. Is there an option that I miss somewhere?

Please remember that the code can still work…

is used The TExprParser instance that processes the filter string depends on the resource strings given as STextTrue and STextFalse. You may have another language than English configured for the IDE library. Try switching to English and see if the error disappears.

To solve this problem, the text “False” is usually replaced with the content of resourcestring STextFalse.

By the way, this was corrected in later Delphi versions, even in The literal “false” is also accepted in non-English environments.

I have a TCustomClientDataSet (in memory) for some filtering in a Delphi program.

My filtering code is as follows:

CDSFilteredGroup.Filter :='ACP_type = 1 AND ACP_by_default <> False';
CDSFilteredGroup. Filtered := True;

When I compile and run it, I only get the following error when Delphi (XE4) is installed on my computer:

< pre>CDSFilteredGroup: Champ’False’ non trouvé.

Translation: Field’False’ not found. The same code compiles and runs perfectly on my colleague’s computer, but it’s not mine. I missed it Must there be an option somewhere?

Please remember that the code can still work…

The TExprParser instance used to process the filter string depends on being STextTrue And the resource string given by STextFalse. You may have another language instead of English configured for the IDE library. Try to switch to English and see if the error disappears.

To solve the problem , Usually replace the text “False” with the content of the resourcestring STextFalse.

By the way, this was corrected in a later Delphi version, and the literal “false” is accepted even in a non-English environment .

Leave a Comment

Your email address will not be published.