public bool WriteLog(string Msg)
{
try
{ .........
..............
.........
return true;
}
catch
{
}
} 为什么这样写是错误的呢?
错误消息:"并非所有的代码路径都返回值"
{
try
{ .........
..............
.........
return true;
}
catch
{
}
} 为什么这样写是错误的呢?
错误消息:"并非所有的代码路径都返回值"
调试欢乐多
也就是要写成
public bool WriteLog(string Msg)
{
try
{ .........
..............
.........
return true;
}
catch
{
return false;
}
}