How to do this in VB 2010 (C# to VB conversion)

Posted by user203687 on Stack Overflow See other posts from Stack Overflow or by user203687
Published on 2010-05-19T21:19:18Z Indexed on 2010/05/22 0:50 UTC
Read the original article Hit count: 589

I would like to have the following to be translated to VB 2010 (with advanced syntaxes)


_domainContext.SubmitChanges(
     submitOperation =>
     {
        _domainContext.Load<Customer>(
             _domainContext.GetCustomersQuery(),
              LoadBehavior.RefreshCurrent,
              loadOperation =>
              {
                 var results = _domainContext.Customers.Where(
                         entity => !loadOperation.Entities.Contains(entity)).ToList();

                 results.ForEach( enitity => _domainContext.Customers.Detach(entity));
              }, null);
      }, null);

I managed to get the above with other ways (but not using anonymous methods). I would like to see all the advanced syntaxes available in VB 2010 to be applied to the above.

Can anyone help me on this?

thanks

© Stack Overflow or respective owner

Related posts about vb.net

Related posts about anonymous-methods