Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7860333
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T22:14:49+00:00 2026-06-02T22:14:49+00:00

I am using a WPF application with MVVM model. I want to know how

  • 0

I am using a WPF application with MVVM model. I want to know how to compare
two IEnumerable collection values. I am having two IEnumerable values , named as
AvailablePacks and RecommendedPacks. These two collection have different set of values but they are having common property PackID value. And AvailablePacks having a another property named as Quantity.

Now i want to compare these two IEnumerable collection values based upon PackID value, When the both collection having the same PackID I need to assign that Quantity(Inside of AvailablePacks) value to some variable called PackQuantity Which is declared outside .

I am new to LINQ So i am not able to do this properly.

So How Can i achieve this? Can any one tell me a solution of this?

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T22:14:50+00:00Added an answer on June 2, 2026 at 10:14 pm
      var result = from ap in AvailablePacks  
                 join rp in RecommendedPacks 
                   on ap.PackID equals rp.PackID
                   select new {
                      PackQuantity = ap.Quantity
                   };
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to implement a WPF application using MVVM (Model-View-ViewModel) pattern and I'd like
I am building a WPF 4.0 Application using MVVM. The Model is generated using
I'm writing an application using WPF MVVM. I have a view model with property
In my WPF application using MVVM I noticed that in some cases the CanExecute
My WPF application is structured using the MVVM pattern. The ViewModels will communicate asynchronously
I am building a WPF application and using the MVVM for the first time.
I'm working on a WPF application, and I'm structuring it using the MVVM pattern.
I'm developing a .NET 4.0 application using PRISM and MVVM, as well as WPF.
(using WPF application) I get an error when i want to save a bool
I am using the Model-View-ViewModel architecture in a WPF application I am building, and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.