IDEIntf: improved error messages when it is not possible to get the database fields list, issue 39304

This commit is contained in:
Maxim Ganetsky 2021-08-03 01:20:03 +03:00
parent d47af6022a
commit cbb9bd7d09
3 changed files with 6 additions and 5 deletions

View File

@ -189,7 +189,7 @@ begin
FieldsList := TFieldsListFrm.Create(Self, LinkDataset, Designer);
except
on E:Exception do begin
ShowMessage(fesNoFields+^M+fesCheckDSet+^M^M+E.Message);
MessageDlg(fesNoFields+^M+fesCheckDSet+^M^M+Format(fesErrorMessage, [E.Message]), mtError, [mbOK], 0);
exit;
end;
end;

View File

@ -431,7 +431,7 @@ begin
end;
except
on E:Exception do begin
ShowMessage(fesNoFields+^M+fesCheckDSet+^M^M+E.Message);
MessageDlg(fesNoFields+^M+fesCheckDSet+^M^M+Format(fesErrorMessage, [E.Message]), mtError, [mbOK], 0);
end;
end;
end;

View File

@ -401,10 +401,11 @@ resourcestring
fesFeTitle = 'Edit Fields ...';
oisAddFields = '&Add fields';
oisAddFieldsFromFieldDefs = 'Add fields from FieldDefs';
fesNoFields = 'It was not possible to get the dataset field''s list';
fesCheckDset = 'Check dataset settings';
fesNoFields = 'It was not possible to get the dataset fields list.';
fesCheckDset = 'Check dataset settings.';
fesErrorMessage = 'Error message:' + LineEnding + '%s';
fesFlTitle = 'FieldDefs';
fesNoFieldsNote = 'Field''s list is not available, can''t check for duplicates';
fesNoFieldsNote = 'Fields list is not available, can''t check for duplicates.';
oisIncompatibleIdentifier = 'Incompatible Identifier';
oisIsNotAValidMethodName = '"%s" is not a valid method name.';
oisTheIdentifierIsNotAMethodPressCancelToUndoPressIgn = 'The identifier "%s" is not a method.'