Jump to content
Xtreme .Net Talk

Recommended Posts

  • *Experts*
Posted

I have a collection which I wish to use as a databinding source. Therefore in the collection I have:

Public Class MyTypedCollection

   Inherits Collections.DictionaryBase
   Implements ITypedList

End Class

 

But ITypedList has two required functions and I really don't understand the documentation...what should go in:


   Function GetListName(ByVal listAccessors() As PropertyDescriptor) As String Implements ITypedList.GetListName
       '\\ what goes here?
   End Function

   Function GetItemProperties(ByVal listAccessors() As PropertyDescriptor) As PropertyDescriptorCollection Implements ITypedList.GetItemProperties
       '\\ What goes here as well?
   End Function

Printer Monitor for .NET? - see Merrion Computing Ltd for details
  • *Gurus*
Posted

It's my understanding, if I remember correctly, that GetItemProperties should return the actual properties to be bound to. Say for instance you had a DataView-- you wouldn't want to bind to its properties, but instead bind to the properties of the DataTable it contains.

 

With a simple collection though I don't understand why you would need to implement this. IList would be the more appropriate choice.

  • *Experts*
Posted
It's not really a simple collection - I am overstating that part of things...it is a DictionaryBase derived collection of PrintJobs which have readonly, conditional read/write and should not be bound properties...
Printer Monitor for .NET? - see Merrion Computing Ltd for details

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...