Given a class:
class foo { public string a = \"\"; public int b = 0; }
Then a generic list of them:
var list = new List
All you need to do is introduce some brackets so that your anonymous method can support multiple lines:
list.ForEach(i => { i.a = "hello!"; i.b = 99; });