Rick,
Well, it doesn't make much sense that you would expose a setter for the
property that exposes the List. You can expose the List<Tas read only,
(just a getter) and the designer won't try and set the value.
From a design standpoint, it doesn't make sense to allow code outside of
your control replace the entire collection (meaning, the List<Titself).
Rather, it should just modify elements in that collection.
--
- Nicholas Paldino [.NET/C# MVP]
-
mv*@spam.guard.caspershouse.com
"Rick" <ad***@thebinarysolution.comwrote in message
news:72**********************************@q3g2000h sg.googlegroups.com...
I've created a GUI control for my form. It has a public property
that's a generic list. When I use the control on a form, Visual
studio automatically generates the code in InitializeComponents. The
generic list property always gets set null here. How do prevent this
code property from being generated in InitializeComponents?