Hi how to set R G B
values in System.Drawing.Color.G
?
which is like System.Drawing.Color.G=255;
is not allowed because its read only
Property or indexer 'System.Drawing.Color.G' cannot be assigned toit is read only
i just need to create a Color
Object by assigning custom R G B
values
You could create a color using the static FromArgb method:
Color redColor = Color.FromArgb(255, 0, 0);
You can also specify the alpha using the following overload.