7.1.1 Visual Studio debugging and error handling

Source: Internet
Author: User

VS has an output window. The call method is

Note that the window has two modes. You can select these modes by using the drop-down list. You can switch between build and debug modes. The build and debug modes show the information during compilation and running respectively. The "write to output window" mentioned in this section actually refers to "debug mode view for writing to output window ".

In addition, you can create a log file to add information to the log file when running the application. The skills used to write information into a log file are the same as those used to write text to an output window, but you need to understand how to access the file system from a C # application. Now, you can add this function to a later part of this book, because even if you are not familiar with file access techniques, you can write information to log files.

 

Output debugging information

Writing text to the output window during running is very simple. You can replace console. writle () with the required call to write the text to the desired place. You can use the following two commands:

 

7.1.1 Visual Studio debugging and error handling

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.