如何调试C#程序 [英] how to debug a C# program

查看:73
本文介绍了如何调试C#程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何跟踪和调试我的C#和Java程序,请告诉我其中涉及的步骤?

how to trace & debug my C# & java programs please tell me the steps involved in it?

推荐答案

在这里,看看:Microsoft支持:如何在Visual C#中进行跟踪和调试 [ ^ ]
Here, have a look: Microsoft Support: How to trace and debug in Visual C#[^]


忽略Java端-我不使用它,因此无法发表评论(但这不会有很大的不同)VS中内置了调试器.

当您使用F5键运行程序时,它会将调试器附加到应用程序上,并允许您执行各种操作,从基本的添加断点"(当程序到达指定的行数时停止运行).代码)以查看修改后的变量值,并单步执行代码以完全遵循所发生的事情.

怎么做?运行程序,然后使用调试"菜单选择要执行的操作.

我们无法为您提供完整的解释,那里太多了.但是,请从此处开始阅读: http://msdn.microsoft.com/en-us/library/sc65sadd.aspx [ ^ ]和您可能会了解基础知识.
Ignoring the Java side - I don''t use it, so I can''t comment (but it won''t be very different) the debugger is built into VS.

When you run your program with the F5 key, it attaches a debugger to the application, and allows you to do an enormous range of things, from the basic "add a breakpoint" (which stops your program running when it reached a specified line of code) to viewing an amending variable values and single stepping through the code to follow exactly what is going on.

How to do it? Run the program, and use the "Debug" menu to select what you want to do.

We can''t give you a full explanation, there is too much there. But start reading here: http://msdn.microsoft.com/en-us/library/sc65sadd.aspx[^] and you might get the basics.


无需忽略Java方面!

如果您使用像Eclipse或Netbeans之类的像样的IDE,则包括调试等.
两者都是 FREE ,Java中的每个开发软件都应使用其中之一.

实际上,您也可以使用Eclipse用C#开发软件.
No need to ignore the Java side!

Debugging etc. is included If you use a decent IDE like Eclipse or Netbeans.
Both are FREE and one of them should be used by every one developing software in Java.

You can actually also develop software in C# with Eclipse.


这篇关于如何调试C#程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆