我不确定如何将带有委托(delegate)的 C# 代码转换为 Visual Basic 代码,你能帮我吗?
List<XmlUser> matchingUsers = this.Store.Users.FindAll(delegate(XmlUser user)
{
return user.Email.Equals(emailToMatch,
StringComparison.OrdinalIgnoreCase);
}
);
最佳答案
Dim matchingUsers As List(Of XmlUser) = Me.Store.Users.FindAll( _
Function(user As XmlUser) user.Email.Equals(emailToMatch, StringComparison.OrdinalIgnoreCase) _
)
关于c# - 如何将此 C# 代码转换为 Visual Basic,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/3522105/