Skip to main content

NotNullEmpty

function NotNullEmpty: Boolean

Example

procedure ScriptEvent(var Value: variant);
begin
if Field.NotNullEmpty then
Value := Field.AsStringTrim
else
Value := 'UNKNOWN';
end;

Usage

NotNullEmpty returns true when the field's converted and trimmed string value is not empty.

Additional Technical Info

NotNullEmpty is the exact logical negation of IsNullEmpty.

It returns false for database null, empty string and text consisting only of characters removed by Delphi Trim. It normally returns true for numeric zero, Boolean false and date/time zero because their string conversions are nonempty.

This is a converted-text test, not merely not IsNull and not a field-type test. Formatting and custom field conversion can affect the text or raise. It reads the current record and has no write/navigation side effect.

External references

Created 2026-07-15