本文介绍了我收到一个错误,如mscorlib.dll中出现类型为'System.StackOverflowException'的未处理异常的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我的代码如下所示
my code is look like below
public List<teamdata> GetMemberTeams(int memberid)
{
var memberTeam =
( from m in _DataContext.MemberLogins
join tm in _DataContext.TeamMembers on m.MemberLoginID equals tm.MemberLoginID
join t in _DataContext.Teams on tm.TeamID equals t.TeamID
where m.MemberID == memberid select new TeamData{TeamID=t.TeamID, TeamName= t.TeamName, TeamStatus=t.TeamStatus}).ToList();
return GetMemberTeams(memberid);
}
所以我收到团队详细信息错误
类型'系统未处理的例外.stackOverflowException'发生在mscorlib.dll中
代码块添加 - OriginalGriff [/ edit]
so am getting team details error comes
An unhandled exception of type 'System.StackOverflowException' occurred in mscorlib.dll
[edit]Code block added - OriginalGriff[/edit]
推荐答案
public List<teamdata> GetMemberTeams(int memberid)
{
...
return GetMemberTeams(memberid);
}
我认为你的意思是:
I think you meant:
public teamdata GetMemberTeams(int memberid)
{
...
return memberTeam[memberid];
}
这篇关于我收到一个错误,如mscorlib.dll中出现类型为'System.StackOverflowException'的未处理异常的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!