* Moved constant to rtlconsts

git-svn-id: trunk@45521 -
This commit is contained in:
michael 2020-05-28 09:45:43 +00:00
parent e0c5ac1682
commit 6b79e2c2c3
2 changed files with 4 additions and 3 deletions

View File

@ -47,7 +47,7 @@ Type
implementation
uses typinfo;
uses rtlconsts,typinfo;
{ TNullable }
@ -59,7 +59,7 @@ end;
function TNullable.GetValue: T;
begin
if not FHasValue then
raise EConvertError.CreateFmt('Cannot convert Null to type %s',[PtypeInfo(TypeInfo(T))^.Name]);
raise EConvertError.CreateFmt(SErrCannotConvertNullToType,[PtypeInfo(TypeInfo(T))^.Name]);
Result:=FValue;
end;

View File

@ -309,7 +309,8 @@ ResourceString
SErrCannotWriteToProperty = 'Cannot write to property "%s".';
SErrCannotReadProperty = 'Cannot read property "%s".';
SErrNoNameValuePairAt = 'No name=value pair at position %d.';
SErrCannotConvertNullToType = 'Cannot convert Null to type %s';
{ ---------------------------------------------------------------------
Keysim Names
---------------------------------------------------------------------}