本文介绍了如何停止Visual Studio进入(全部中断)暂停按钮上的program.cs的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

真烦人.

Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new mainForm()); <-- pausing visual studio breaks here.

谢谢大家.

推荐答案

仅当您的应用程序处于空闲状态(即它实际上正在执行Application.Run)时,调试器才会在那里暂停.

The debugger wil only pause there if your application is in an idle state (i.e it is actually executing Application.Run).

如果您真的不愿意到此结束,则可以尝试在调用Application.Run的方法上使用'DebuggerNonUserCode'属性,但我不建议这样做.

If you really don't wont to end up there, you might try using the 'DebuggerNonUserCode' attribute on the method that calls Application.Run, but I wouldn't recommend it.

这篇关于如何停止Visual Studio进入(全部中断)暂停按钮上的program.cs的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-27 06:58