alguidelines/content/docs/NAVPatterns/3-cal-coding-guidelines/readability/spacing-brackets-and/index.md
2022-02-24 14:45:35 +01:00

48 lines
No EOL
595 B
Markdown

+++
title = "Spacing Brackets and ::"
weight = 1130
tags = ["C/AL","Readability"]
categories = ["Best Practice"]
+++
There must be no spaces characters before and after [] dimension brackets symbols or :: option symbols.
Bad code
```al
A[i] [j] := Amt;
```
Good code
```al
A[i][j] := Amt;
```
Bad code
```al
"Currency Exchange Rate"."Fix Exchange Rate Amount" :: Currency:
```
Good code
```al
"Currency Exchange Rate"."Fix Exchange Rate Amount"::Currency:
```
Bad code
```al
IF FIND (Which) THEN
```
Good code
```al
IF FIND(Which) THEN
```