PC Review


Reply
Thread Tools Rate Thread

Collection Adding Everything Twice - Design Time

 
 
Adam Dockter
Guest
Posts: n/a
 
      10th Jan 2005
I have implemented a simple collection of objects using IList and put the
following attributes on the collection property.

[Category("Behavior")
,Browsable(true)
,DesignerSerializationVisibility(DesignerSerializationVisibility.Content)
,EditorAttribute(typeof(CollectionEditor),typeof(UITypeEditor))]

Everything compiles fine but if I add objects at design time it trys to add
all the objects multiple times.
For example:
I add OBJ1 - this works fine.
When I add OBJ2 - it first adds OBJ1 and then adds OBJ2
When I add OBJ3 - first it adds OBJ1 then OBJ2 the OBJ3.

It doesn't serialize like this but it causes the display to do this. Has
anyone else ever ran into this. It happens to me on all my collections. I
am sure I am doing something wrong I just don't know what. If you would
like a copy of the source let me know. It is too much to post in this
message.

Any help is appreciated.
-Adam dR.


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: How to serialize a custom collection at design time sloan Microsoft C# .NET 0 15th Dec 2006 03:44 PM
Adding items in collection property during design mode Saimeera Microsoft ASP .NET 0 10th May 2006 12:34 PM
Custom collection was binded at design time, but does not populates datagrid at run time... SammyBar Microsoft Dot NET Framework Forms 2 21st Sep 2005 08:29 PM
Custom collection was binded at design time, but does not populates datagrid at run time... SammyBar Microsoft Dot NET 2 21st Sep 2005 08:29 PM
Design Time Collection Adam Microsoft C# .NET 0 15th Nov 2004 07:33 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:49 PM.