Here's the problem: you have a collection of objects with lots of information in those objects (the "rich" objects). You also have a collection of objects that represent a selection your user made in your application's UI (the "selected" objects). Unfortunately, your "selected" collection is a different and less useful set of objects; you really want to work with the "rich" objects. So Your problem is finding all the matching objects from the "rich" collection, based on the objects in the "selected" collection.
A LINQ Join solves the problem. Joining the two collections together gives you a new collection of the "rich" objects that have a matching item in the "selected" collection. In the LINQ statement's Join/On clause, you just need to specify the properties to be used to join the two collections together.
Dim usrs = From cu In context.CompanyUsers
Join id In SelectedUsers On cu.ID Equals id
Posted by Peter Vogel on 07/08/2013 at 1:16 PM
With advanced generative AI systems reshaping software development, Microsoft's Mads Kristensen detailed the many ways AI will improve coding in Visual Studio.
With Google recently releasing a generative AI-powered search bot called Bard to rival Microsoft's "new Bing" search experience, we put both to the test, feeding them identical questions about Visual Studio and .NET.
GPT-4, the advanced generative AI model from Microsoft partner OpenAI, is now powering the new GitHub Copilot X and the Azure OpenAI Service.
Microsoft shipped TypeScript 5.0 with new features claimed to make the language smaller, simpler and faster.
A new tool that can generate code is being previewed in the Visual Studio Code Insiders channel seeks to ease the tedious data preparation process that data scientists need to go through to get good data for successful analysis projects.
> More Webcasts