Skip to content

Commit f5f65d6

Browse files
committed
Many small fixes
1 parent c4581aa commit f5f65d6

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

Content/Chapter-11-tricks-and-hacks/debugging-techniques/debugging-techniques.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Debugging plays an important role in the process of creating software, which is
1111

1212
Visual Studio gives us **a built-in debugger**, thanks to which we can place **breakpoints** at places we have chosen. When it reaches a **breakpoint**, the program **stops running** and allows **step-by-step running** of the remaining lines. Debugging allows us to **get in the details of the program** and see where exactly the errors occur and what is the reason for this.
1313

14-
In order to demonstrate the debugger, we will use the following program:
14+
In order to demonstrate how to use the debugger in VS, we will use the following C# program:
1515

1616
```csharp
1717
static void Main(string[] args)
@@ -33,11 +33,12 @@ In order to start **the program in debug mode**, we choose \[**Debug**\] ->
3333

3434
![](/assets/chapter-11-images/02.Debugger-02.jpg)
3535

36-
After starting the program, we can see that it **stops executing** at line 11, where we placed our breakpoint. The code in the current line **is colored in yellow** and we can **run it step by step**. In order to go to **the next line**, we use the key \[**F10**\]. **We can see that the code on the current line hasn't executed yet**. **It executes when we go to the next line**:
36+
After starting the program, we can see that it **stops executing** at line 11, where we placed our breakpoint. The code in the current line **is colored in yellow** and we can **run it step by step**. In order to go to **the next line**, we use the key \[**F10**\]. We can see that **the code on the current line hasn't executed yet** and it is displayed in yellow. It will execute when we go ahead with the debugging the next line.
37+
38+
The screenshot below shows **the Visual Studio debugger**, stopped at the breakpoint and waiting for the developer to decide what to do (e.g. execute the next command or stop the program):
3739

3840
![Debugger](/assets/chapter-11-images/02.Debugger-03.jpg)
3941

40-
From the **Locals** window we can observe **the changes in the local variables**. In order to open the window, you must choose \[**Debug**\] -> \[**Windows**\] -> \[**Locals**\].
42+
From the **Locals** window we can observe **the changes in the local variables** or **modify their values at runtime**. In order to open the window, you must choose \[**Debug**\] -> \[**Windows**\] -> \[**Locals**\].
4143

4244
![Debugger](/assets/chapter-11-images/02.Debugger-04.jpg)
43-

0 commit comments

Comments
 (0)