Home > Article > Backend Development > Simple record of C# conditional compilation (detailed explanation with pictures and text)
Conditional compilation is something that C# has more than Java, but after I asked my seniors for advice, they all said that conditional compilation is not often used in actual project development. The following is just a record of the steps. , friends in need can refer to it.
Step one: Create a new solution configuration in the configuration manager
# #Step 2: Define conditional compilation symbols: Step 3: Use customized conditional compilation in the code
#if CustomDebug Console.WriteLine("dsads"); #endif
The above is the detailed content of Simple record of C# conditional compilation (detailed explanation with pictures and text). For more information, please follow other related articles on the PHP Chinese website!