Desktop version

Main > Knowledge Base > Best practices > Code conventions > Using 1C:Enterprise script clauses > Limitations to usage of the Goto operator > Best practices > Code conventions > Using 1C:Enterprise script clauses > Limitations to usage of the Goto operator > Best practices > Code conventions > Using 1C:Enterprise script clauses > Limitations to usage of the Goto operator

Limitations to usage of the Goto operator

This article describes the standards that apply to the usage of the Goto operator. All of the listed recommendations are mandatory unless noted otherwise.

This recommendation is optional

1. We recommend that you do not use the Goto operator because this might impact the clarity of your module structure, making the connections between script fragments and the order of their execution harder to understand. We recommend that you use other 1C:Enterprise script operators instead.

 Incorrect:

 If ChartOfCalculationTypes = Object.ChartOfCalculationTypes Then
  
  Goto ~ChartOfCalculationTypes;
  
 EndIf;

 Correct:

 If ChartOfCalculationTypes = Object.ChartOfCalculationTypes Then
  
  ProcessChartOfCalculationTypes();
  
 EndIf;

2. Do not use the Goto operator in common modules with the Client (managed application) flag, command modules, and client script of managed form modules because 1C:Enterprise web client does not support this operator.

Next page: PredefinedValue function usage specifics





© 1C LLC. All rights reserved
1C Company respects the privacy of our customers and visitors
to our Web-site.