LINQ VB.NET variable not found when looping through grouped query
Posted
by Ed Sneller
on Stack Overflow
See other posts from Stack Overflow
or by Ed Sneller
Published on 2010-03-29T21:38:00Z
Indexed on
2010/03/29
21:43 UTC
Read the original article
Hit count: 284
I'm trying to do the following LINQ grouping, which works in the debugger (the results are populated in the GroupedOrders object. But VS 2008 gives me the following error at design time...
Name 'x' is not declared
Dim GroupedOrders = (From m In thisConsultant.orders _
Group m By Key = m.commCode Into Group _
Select commCode = Key, orders = Group)
For Each x In GroupedOrders
Next
VS 2008 gives me the following error,
© Stack Overflow or respective owner