写程序时try,catch查看报错的行号
try
{
////////////////
代码段
////////////////
}
catch
(Exception ex)
{
MessageBox.Show(ex.StackTrace);
}
据说在debug里可以用,release里不行,但是我很少用release。。
try
{
////////////////
代码段
////////////////
}
catch
(Exception ex)
{
MessageBox.Show(ex.StackTrace);
}