Click here to Skip to main content
15,909,466 members
Home / Discussions / C#
   

C#

 
GeneralRemove DataGridView items Pin
bdiepeveen9-Apr-08 0:19
bdiepeveen9-Apr-08 0:19 
AnswerRe: Remove DataGridView items Pin
Eslam Afifi9-Apr-08 7:25
Eslam Afifi9-Apr-08 7:25 
GeneralRe: Remove DataGridView items Pin
bdiepeveen9-Apr-08 20:55
bdiepeveen9-Apr-08 20:55 
GeneralRe: Remove DataGridView items Pin
Eslam Afifi10-Apr-08 6:06
Eslam Afifi10-Apr-08 6:06 
GeneralRe: Remove DataGridView items Pin
bdiepeveen10-Apr-08 21:01
bdiepeveen10-Apr-08 21:01 
AnswerRe: Remove DataGridView items Pin
Eslam Afifi11-Apr-08 1:35
Eslam Afifi11-Apr-08 1:35 
GeneralReportViewer cant open Report simulteniously Pin
bhushan0978-Apr-08 23:42
bhushan0978-Apr-08 23:42 
GeneralAdd a list of System.Drawing.Color as a property Pin
Rey99998-Apr-08 23:39
Rey99998-Apr-08 23:39 
Hello Everyone.

I am creating a custom control. I need to add, amongst its properties, a bunch of lists.
One of those is a list of System.Drawing.Color objects.
I create the property as usual:
<br />
private List<System.Drawing.Color> _Colors = new List<System.Drawing.Color>();<br />
public List<System.Drawing.Color> Colors<br />
{<br />
    get { return _Colors; }<br />
    set { _Colors = value; }<br />
}


This, however, seems not to get the things done quite right. Actually, I get this error:
<br />
Cannot create an object of type 'System.Collections.Generic.List`1[[System.Drawing.Color, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a]]' from its string representation '(Collection)' for the 'Colors' property.<br />


Do I need to add something to my code to have this property working?

Thanks in advance - any help would be much appreciated.

Rey9999

~~~ From Milano to The Hague, easy as it goes ~~~

GeneralRe: Add a list of System.Drawing.Color as a property Pin
Christian Graus9-Apr-08 0:07
protectorChristian Graus9-Apr-08 0:07 
GeneralRe: Add a list of System.Drawing.Color as a property Pin
Rey99999-Apr-08 2:20
Rey99999-Apr-08 2:20 
GeneralRe: Add a list of System.Drawing.Color as a property Pin
Giorgi Dalakishvili9-Apr-08 4:06
mentorGiorgi Dalakishvili9-Apr-08 4:06 
GeneralRe: Add a list of System.Drawing.Color as a property Pin
Giorgi Dalakishvili9-Apr-08 0:08
mentorGiorgi Dalakishvili9-Apr-08 0:08 
GeneralAVI file Pin
arshan8-Apr-08 23:28
arshan8-Apr-08 23:28 
GeneralRe: AVI file Pin
Christian Graus8-Apr-08 23:58
protectorChristian Graus8-Apr-08 23:58 
GeneralRe: AVI file Pin
J4amieC8-Apr-08 23:59
J4amieC8-Apr-08 23:59 
GeneralRe: AVI file Pin
Eduard Keilholz9-Apr-08 0:11
Eduard Keilholz9-Apr-08 0:11 
GeneralRe: AVI file Pin
J4amieC9-Apr-08 0:50
J4amieC9-Apr-08 0:50 
GeneralCross-thread operation Pin
mehrdadc488-Apr-08 22:51
mehrdadc488-Apr-08 22:51 
GeneralRe: Cross-thread operation Pin
laserbaronen8-Apr-08 23:10
laserbaronen8-Apr-08 23:10 
GeneralRe: Cross-thread operation Pin
Christian Graus9-Apr-08 0:00
protectorChristian Graus9-Apr-08 0:00 
GeneralRe: Cross-thread operation Pin
GuyThiebaut9-Apr-08 3:40
professionalGuyThiebaut9-Apr-08 3:40 
GeneralRe: Cross-thread operation Pin
Christian Graus9-Apr-08 11:40
protectorChristian Graus9-Apr-08 11:40 
GeneralRe: Cross-thread operation Pin
half-life9-Apr-08 5:34
half-life9-Apr-08 5:34 
Questionmouse scroll list view Pin
Pathetic Logic8-Apr-08 21:19
Pathetic Logic8-Apr-08 21:19 
GeneralRe: mouse scroll list view Pin
Christian Graus8-Apr-08 22:01
protectorChristian Graus8-Apr-08 22:01 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.