Export (0) Print
Expand All

Edit and Continue (Visual Basic): Unsupported Method and Property Body Edits 

This topic applies to:

Visual Studio Edition

Visual Basic

C#

C++

J#

Express

Yes

No

No

No

Standard

Yes

No

No

No

Pro/Team

Yes

No

No

No

Edit and Continue enables you to stop program execution in Break mode, make changes to the executing code, and resume program execution with the newly incorporated changes. Declarative code edits that affect the public structure of a class are generally prohibited, but most edits you might make to a method, property body, or private declarations within a class are allowed. For more information, see Edit and Continue (Visual Basic): Unsupported Declaration Edits.

There are some exceptions described in the following sections. Whenever possible, Edit and Continue marks code that cannot be edited as light gray. If you need to make any of these unsupported changes, you must stop debugging, make the changes, and start a new debugging session.

  • Removing a static local variable.

  • Modifying the condition of a While loop, when the instruction pointer is in the condition.

  • Modifying the lower or upper bound of a For statement, when the instruction pointer is in the expression.

  • Adding or removing a Next loop, when the instruction pointer is used in the enumerator expression.

  • Adding a For Each loop, when the instruction pointer is in the body of the loop.

  • Changing the iterator of a For Each loop, when the instruction pointer is in the enumerator expression or the body of the loop.

  • Changing the enumerator expression of a For Each loop, when the instruction pointer is in the enumerator expression.

  • Changes to the generic method itself or generic method body are not supported. Instantiation of a generic type or calls to existing generic methods can be added, deleted, or changed.

  • Changing the invocation statement of a method that is on the call stack.

  • Adding a Try...Catch block, when the instruction pointer ends up in the Catch block or the Finally block.

  • Removing a Try...Catch block, when the instruction pointer is in a Catch block or the Finally block.

  • Adding six or more nested Try statements around the current instruction pointer.

  • Adding a Using block around the current instruction pointer.

  • Adding a SynchLock block around the current instruction pointer.

  • Adding, removing, or modifying a user-defined #region.

Show:
© 2014 Microsoft