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 6607359
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T19:29:42+00:00 2026-05-25T19:29:42+00:00

I got a well-constituted ObservableCollection and I’d like to inspect into it. The definition

  • 0

I got a “well-constituted” ObservableCollection and I’d like to inspect into it.
The definition of it is :

private Dictionary<string, ObservableCollection<DependencyObject>> _DataPools = new Dictionary<string, ObservableCollection<DependencyObject>>();

(yep it’s an obsCol with an obsCol in it, but it IS ok, the problem’s not here)

I tried 2 different ways but they both don’t work…

1) .Items

foreach(ObservableCollection<DependencyObject> obj in _DataPools.Items)
        {
            blablaaaa;
            ....
        }

.Items doesn’t work but when I look in the C#doc, Items is a valid field… (just like “Count”, and “Count” works…)

2) Count + [x] acces :

var nbItems = _DataPools.Count;

        for (int i = 0; i < nbItems; i++)
        {
            Console.WriteLine("Items : " + _DataPools[i].XXX); //XXX = ranom method
        }

_DataPools[i] doesn’t work but on the web I found a couple of example where it is used oO

I tried a couple of other “exotic” things but I really can’t go over it…

Any help will be welcomed !

Thx in advance and sry for my langage, im french -_-
(sry for my president too !)

  • 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-05-25T19:29:42+00:00Added an answer on May 25, 2026 at 7:29 pm

    _DataPool is not an observable collection in an observable collection. It’s a dictionary that contains observable collections. To get the collections from the dictionary, use the Values property:

    foreach (ObservableCollection<DependencyObject> obj in _DataPools.Values)
    {
        // some code
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've got a flex component which works pretty well but unfortunately turns into a
Well, I got an object called Mamamia and inside of it has some string
Alright well I recently got into normalizing my database for this little side project
Well I recently got into PantherAds and got my ad script to place on
Well ive got this code that creates a table from JSON data. If a
I got this code from someone and it works very well, I just want
I've got an after insert trigger that works well. However, I want it to
Well, now that I've finally got my stupid ODBC stuff configured, I took a
Well, I´m developing a wpf application and I got a strange error on design
I've got some 3rd party beans that have method signatures that fit quite well

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.