Formatting, JScript, Options Dialog Box

These settings let you set preferences for when and how automatic formatting inserts physical line breaks, spacing, and new lines in the Source view markup editor.

To access this dialog box

  1. In Microsoft Visual Web Developer, click Tools, and then click Options.

    The Options dialog box opens.

  2. In the left panel, expand the Text Editor node, expand the JScript node, and then click Format.

    If you have configured your environment settings for Web development, the Format node is at the top level. For more information about environment settings, see How to: Change Select Settings.

Tasks

UI Elements

Automatic Formatting

These options determine when formatting occurs in Source view.

  • Format completed line on Enter
    When this option is selected, the editor automatically formats the line after Enter is pressed.

  • Format completed statement on ;
    When this option is selected, the editor automatically formats the line after the semicolon is pressed.

  • Format completed block on }
    When this option is selected, the editor automatically formats the line after a closing brace is pressed.

  • Format on paste
    When this check box is selected, the editor reformats the contents when you paste them into the page, using the currently defined formatting rules. If this check box is not selected, the editor pastes the contents in using the exact formatting of the existing content.

    .

New Lines

These options determine whether the editor puts an open brace for functions and control blocks on a new line.

  • Place open brace on new line for functions
    When this option is selected, the editor moves the open brace associated with a function to a new line.

  • Place open brace on new line for control blocks
    When this option is selected, the editor moves the open brace associated with a control block (for example, If and While control blocks) to a new line.

Spacing

These options determine how spaces are inset in Source view.

  • Insert space after comma delimiter
    When this option is selected, the editor adds a space after a comma delimiter.

  • Insert space after semicolon in 'for' statement
    When this option is selected, the editor adds a space after each semicolon in the 'for' loop header.

  • Insert space before and after binary operators
    When this option is selected, the editor adds a space before and after a binary operator (for example, +, -, &&, ||).

  • Insert space after keywords in control flow statements
    When this option is selected, the editor adds a space after JScript keywords in a control flow statement.

See Also

Reference

General, JScript, Options Dialog Box