FOR loop (form)
Applies To: Microsoft Dynamics AX 2012 R3, Microsoft Dynamics AX 2012 R2, Microsoft Dynamics AX 2012 Feature Pack, Microsoft Dynamics AX 2012
Click Product information management > Common > Product builder > Product models. Double-click a product model and then click Product model. In the lower pane, right-click the Modeling tree node and then click New > FOR node.
Use this form to insert a FOR node into the modeling tree.
Note
This information applies only to Product builder.
Note
Make sure that the control variable makes the condition FALSE; otherwise, the FOR node (and therefore the entire configuration) will continue to run without stopping.
Navigating the form
The following tables provide descriptions for the controls in this form.
Button
Button |
Description |
---|---|
Test |
Test the FOR loop code. |
Fields
Field |
Description |
|
---|---|---|
Description |
The description of the loop. |
|
Initialization |
Set the control variable for the loop to the value it should have when the loop begins running. For example, if the control variable is called counter, the following line of code would initialize it to the value one: counter = 1 |
|
Step |
Specify an operation for updating the control variable. This operation will be carried out once for each iteration of the loop. For example, the step you specify could be to add one to the value of counter: counter = counter + 1 –or– counter ++ |
|
Expression |
Specify the state that the control variable should be in for the loop to continue running. The expression should normally be a logical condition, and when this condition is FALSE, running the loop ends. |
See also
Announcements: To see known issues and recent fixes, use Issue search in Microsoft Dynamics Lifecycle Services (LCS).