Variable Already Scoped
Categories:
Do not use scope ‘’.’’ qualifier unnecessarily when a variable is already implicitly or explicitly scoped. It keeps the code simpler.
Bad code
ReturnRcptHeader.SETRANGE(ReturnRcptHeader."Return Order No.","Document No.");
Good code
ReturnRcptHeader.SETRANGE("Return Order No.","Document No.");
Bad code
WITH ChangeLogSetupTable DO BEGIN
...
IF ChangeLogSetupTable.DELETE THEN
...
END;
Good code
WITH ChangeLogSetupTable DO BEGIN
...
IF DELETE THEN
...
END;
Feedback
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.
Last modified October 4, 2024: Merge pull request #249 from Busschers/ErrorHandling-ListOfReferenceText (5e76983)
by Arend-Jan Kauffmann