Tag: CASE
Some Compounds Statements
Have a look at these code samples and tell me where a compound statement, i.e. BEGIN-END, should be constructed to get the code work right. Just dare without going into NAV and verify. [8-|] Sample 1 1. SalesCommentLine.SETRANGE(“Document Type”,SalesQHeader.”Document Type”);2. SalesCommentLine.SETRANGE(“No.”,SalesQHeader.”No.”);3. WHILE SalesCommentLine.FIND(‘-‘) DO4. SalesCommentLine.DELETE;5. SalesCommentLine.”Document Type” := SalesOrderHeader.”Document Type”;6. SalesCommentLine.”No.” := SalesOrderHeader.”No.”;7. …
NAV2013 Beta to RTM – Some Striking Code Changes #7: CASE Layout
Although the coding standards are unambiguous about the layout of CASE statements, there has always been practiced an alternative flavor. Both within MS and outside. This is the standard syntax: And this is the alternative flavor: Note that: the alternative is only used when the statement following the value set…
Some Compounds Statements
Have a look at these code samples and tell me where a compound statement, i.e. BEGIN-END, should be constructed to get the code work right. Just dare without going into NAV and verify. [8-|] Sample 1 1. SalesCommentLine.SETRANGE(“Document Type”,SalesQHeader.”Document Type”);2. SalesCommentLine.SETRANGE(“No.”,SalesQHeader.”No.”);3. WHILE SalesCommentLine.FIND(‘-‘) DO4. SalesCommentLine.DELETE;5. SalesCommentLine.”Document Type” := SalesOrderHeader.”Document Type”;6. SalesCommentLine.”No.” := SalesOrderHeader.”No.”;7. …
NAV2013 Beta to RTM – Some Striking Code Changes #7: CASE Layout
Although the coding standards are unambiguous about the layout of CASE statements, there has always been practiced an alternative flavor. Both within MS and outside. This is the standard syntax: And this is the alternative flavor: Note that: the alternative is only used when the statement following the value set…