判断当前程序是在调试环境下运行?

if (System.Diagnostics.Debugger.IsAttached)

            {

                this.textBox1.Text = "debug";

            }

            else



            {

                this.textBox1.Text = "NOdebug";

                

            }

 

你可能感兴趣的:(调试)