Share via

How to: Step Into a Specific Function

This topic applies to:


Visual Basic




Web Developer


Topic applies Topic applies Topic applies Topic applies Topic applies

Pro, Premium, and Ultimate

Topic applies Topic applies Topic applies

Topic applies

Topic applies

When you are stepping into a nested function call, you can use Step Into Specific, located on the shortcut menu, to choose which function you want to step into. For example, on a call to Func1(Func2()), you could choose to step into Func1 or Func2. This command works for any number of nesting levels.

In earlier versions of Visual Studio, this feature worked only for native code. In the most recent version, stepping into a specific function works for both managed and native code. However, it does not work for stepping between managed and native code.

In native code, Step Into Specific does not work with virtual functions.

In managed code, Step Into Specific allows you to step into properties and operators, even if you step into properties and operators is turned off in the Options dialog box.

In managed code, stepping into certain functions requires Just My Code to be turned off. If you use Step Into Specific and select a function that is non-user code, a dialog box appears. It states that the function is non-user code and prompts you to turn off Just My Code. If you choose to turn off Just My Code, the debugger then steps into the selected function. If you choose not to turn off Just My Code, it steps over the function.

To step into a specific function

  1. Advance the execution point to the function call you want to step into. You might use a breakpoint, Step Into, Step Over, or Run To Cursor.

  2. Right-click the source window.

  3. Click Step Into Specific and choose the function you want.

    The debugger executes the function call and breaks at the beginning of the selected function. The Step Into Specific command appears only if the execution point is located on a line of code that contains a nested function.

See Also


How to: Step Into Properties and Operators in Managed Code


Execution Control