ReSharper 2024.1 Help

EditorConfig properties for VB.NET: Line Breaks

Preserve existing formatting

Keep existing line breaks

Property names:

[resharper_]vb_keep_user_linebreaks, [resharper_]keep_user_linebreaks

Possible values:

true | false

Examples:

Before formatting

After formatting, true

Function Sum (x As Integer, _ y As Integer) As Integer Return _ x + y End Function
Function Sum(x As Integer, y As Integer) As Integer Return _ x + y End Function

Before formatting

After formatting, false

Function Sum (x As Integer, _ y As Integer) As Integer Return _ x + y End Function
Function Sum(x As Integer, y As Integer) As Integer Return x + y End Function

Attributes

Place type attribute on the same line

Property names:

[resharper_]vb_place_type_attribute_on_same_line

Possible values:

true | false

Examples:

true

<SomeAttribute> Class C End Class

false

<SomeAttribute> Class C End Class

Place method attribute on the same line

Property names:

[resharper_]vb_place_method_attribute_on_same_line

Possible values:

true | false

Examples:

true

<SomeAttribute> Sub Foo End Sub

false

<SomeAttribute> Sub Foo End Sub

Place property attribute on the same line

Property names:

[resharper_]vb_place_property_attribute_on_same_line, [resharper_]place_property_attribute_on_same_line

Possible values:

true | false

Examples:

true

<SomeAttribute> Public Property MyProperty() As Integer Get End Get Set(ByVal value As Integer) End Set End Property

false

<SomeAttribute> Public Property MyProperty() As Integer Get End Get Set(ByVal value As Integer) End Set End Property

Place event attribute on the same line

Property names:

[resharper_]vb_place_event_attribute_on_same_line, [resharper_]place_event_attribute_on_same_line

Possible values:

true | false

Examples:

true

<SomeAttribute> Public Event MyEvent()

false

<SomeAttribute> Public Event MyEvent()

Place field attribute on the same line

Property names:

[resharper_]vb_place_field_attribute_on_same_line

Possible values:

true | false

Examples:

true

Class C <SomeAttribute> Dim x As Integer End Class

false

Class C <SomeAttribute> Dim x As Integer End Class

Line wrapping

Hard wrap at

Property names:

max_line_length, [resharper_]vb_max_line_length

Right margin (columns)

Possible values:

an integer

Wrap formal parameters

Property names:

[resharper_]vb_wrap_parameters_style, [resharper_]wrap_parameters_style

Possible values:

  • wrap_if_long: Simple wrap

  • chop_if_long: Chop if long or multiline

  • chop_always: Chop always

Examples:

wrap_if_long

Sub Foo(p1 As Integer, p2 As Integer, p3 As Integer) End Sub

chop_if_long

Sub Foo(p1 As Integer, p2 As Integer, p3 As Integer) End Sub

chop_always

Sub Foo(p1 As Integer, p2 As Integer, p3 As Integer) End Sub

Prefer to wrap before '(' in method declaration

Property names:

[resharper_]vb_wrap_before_declaration_lpar, [resharper_]wrap_before_declaration_lpar

Possible values:

true | false

Examples:

true

Sub Foo _ (p1 As Integer, p2 As Integer, p3 As Integer) End Sub

false

Sub Foo(p1 As Integer, p2 As Integer, p3 As Integer) End Sub

Wrap invocation arguments

Property names:

[resharper_]vb_wrap_arguments_style, [resharper_]wrap_arguments_style

Possible values:

  • wrap_if_long: Simple wrap

  • chop_if_long: Chop if long or multiline

  • chop_always: Chop always

Examples:

wrap_if_long

SomeMethod(arg1, arg2, arg3, arg4, arg5)

chop_if_long

SomeMethod(arg1, arg2, arg3, arg4, arg5)

chop_always

SomeMethod(arg1, arg2, arg3, arg4, arg5)

Prefer to wrap before '(' in invocation

Property names:

[resharper_]vb_wrap_before_invocation_lpar, [resharper_]wrap_before_invocation_lpar

Possible values:

true | false

Examples:

true

SomeMethod _ (arg1, arg2, arg3, arg4, arg5)

false

SomeMethod(arg1, arg2, arg3, arg4, arg5)

Wrap extends/implements/handles list

Property names:

[resharper_]vb_wrap_extends_list_style, [resharper_]wrap_extends_list_style

Possible values:

  • wrap_if_long: Simple wrap

  • chop_if_long: Chop if long or multiline

  • chop_always: Chop always

Examples:

wrap_if_long

Class C Implements Ifc1, Ifc2, Ifc3, Ifc4 End Class

chop_if_long

Class C Implements Ifc1, Ifc2, Ifc3, Ifc4 End Class

chop_always

Class C Implements Ifc1, Ifc2, Ifc3, Ifc4 End Class

Wrap multiple declarations list

Property names:

[resharper_]vb_wrap_multiple_declaration_style, [resharper_]wrap_multiple_declaration_style

Possible values:

  • wrap_if_long: Simple wrap

  • chop_if_long: Chop if long or multiline

  • chop_always: Chop always

Examples:

wrap_if_long

Class C Dim x As Integer = 0, y As Integer = 1, s As String = "" End Class

chop_if_long

Class C Dim x As Integer = 0, y As Integer = 1, s As String = "" End Class

chop_always

Class C Dim x As Integer = 0, y As Integer = 1, s As String = "" End Class

Prefer to wrap before operator in binary expression

Property names:

[resharper_]vb_wrap_before_binary_opsign, [resharper_]wrap_before_binary_opsign

Possible values:

true | false

Examples:

true

myField1 = expression1 _ + expression2 _ + expression3 _ + expression4 _ + expression5

false

myField1 = expression1 + expression2 + expression3 + expression4 + expression5
Last modified: 26 May 2024