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

  • Home
  • SEARCH
  • 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 296277
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T06:32:02+00:00 2026-05-12T06:32:02+00:00

I have a helper class that implements ITypedList, to provide objects for databinding against

  • 0

I have a helper class that implements ITypedList, to provide objects for databinding against custom collections.

My implementation allows me to easily specify that I want sub-properties of objects to be available for data binding, for instance I can bind to “Id”, “Name”, and also “Children.Count”.

Now, my problem now is that in order to provide helper-objects to data-bind to such columns, I need to pre-populate a collection with those objects, and then later on when a grid asks for such helper objects through the interface, it will call a method on my object to retrieve them.

The method it calls has a parameter that can be used to specify which accessor objects to retrieve, but it’s invariably null for the .NET DataGridView class, which means I just have to return all the objects I got.

So my question is this. Is there an alternative to ITypedList that I can implement where I will be told explicitly which properties the grid is interested in, so that I don’t have to pre-populate the collection of acccessor objects?

Here’s what my code looks like now:

var wrapper = new TypedListWrapper<Person>(someNormalCollectionClass);
wrapper.BindableProperties = "Id;Name;Children.Count";
grid.DataSource = wrapper;

here’s what I want it to look like:

grid.DataSource = new TypedListWrapper<Person>(someNormalCollectionClass);

Any takers?

  • 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-12T06:32:03+00:00Added an answer on May 12, 2026 at 6:32 am

    If you were to create your own grid, then of course you could implement functionality like this, but not with the DataGridView (or, I would imagine, any current third-party grid control). I would also be wary of the design-time constraints this would place. If PropertyDescriptor initialization is what’s causing your concern, then I would suggest loading up the individual PropertyDescriptor objects with just a name and a type and have actual usage of the object cause it to load any other information that might be required.

    In general, though, these should be inexpensive operations. If you’re having performance anxiety over your ability to obtain the list of properties in a reasonable amount of time, you may need to examine where the bottleneck is in your architecture and try to find a way around it. Apart from that, though, I don’t see an option for you. The databinding system is, by design, consumer agnostic. There is no means for a binding consumer to indicate whether or not he intends to use a descriptor or not. Having something like that would be a real chicken-or-the-egg headache.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 156k
  • Answers 156k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer You will be doing yourself a huge disservice by creating… May 12, 2026 at 10:48 am
  • Editorial Team
    Editorial Team added an answer Is it that you want to apply several jQueryUI themes… May 12, 2026 at 10:48 am
  • Editorial Team
    Editorial Team added an answer Well you can use imagettfbox (see also http://ruquay.com/sandbox/imagettf/) to get… May 12, 2026 at 10:48 am

Related Questions

I have a Java application and I would like to make it extensible. To
This isn't about the different methods I could or should be using to utilize
We wrote a small Windows class library that implements extension methods for some standard
I have a servlet filter that handles errors for both vanilla servlets and JSF
I am currently working on fixing a c# codebase which does not have a

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

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.