Add Else Statement
Purpose
Adds the else block to the conditional.
Availability
Available when the cursor is on an if statement that does not have corresponding else block.
Usage
Place the caret on an if block that has no else block.
Note
The blinking cursor shows the caret's position at which the Code Provider is available.
If│ a Then
Return b
End If
- Use the Ctrl + . or Ctrl + ~ shortcut to invoke the Code Actions Menu.
- Select Add Else Statement from the menu.
After execution, the Code Provider adds the else block to the conditional.
if (a)
return b;
else {
}
If a Then
Return b
Else
End If
We are updating the DevExpress product documentation website and this page is part of our new experience. During this transition period, product documentation remains available in our previous format at documentation.devexpress.com. Learn More...