-
Notifications
You must be signed in to change notification settings - Fork 31
LC0056
Arthur van de Vondervoort edited this page Apr 6, 2024
·
1 revision
This rule checks if the value of the Enum is empty ("") while the Caption property is not empty. The intent of having an empty Enum value can be ambiguous, as such values are not accessible with AL code and also not displayed in the (web)client.
enum 50100 "My Enum"
{
value(0; "") // This will raise the diagnostic
{
Caption = 'New';
}
value(1; "") // Omitting the caption property will not raise a diagnostic
{
}
value(2; "") // An Empty caption will not raise a diagnostic
{
Caption = '';
}
value(3; " ") // An non-Empty Enum value (space) will not raise a diagnostic
{
Caption = 'New';
}
}