C# Passing color into a method.

  • C/++/#
  • Thread starter kiwijoey
  • Start date
  • #1
2
0
How would you go about passing a color into a C# method and using that color inside the method to create a new pen? Assuming everything else is defined

Is it MethodName(Color color)
Graphics pen1 = new Pen(color.Color,1);



or is it something completely different?
 

Answers and Replies

  • #2
harborsparrow
Gold Member
611
154
that should do it
 

Related Threads on C# Passing color into a method.

Replies
16
Views
4K
  • Last Post
Replies
8
Views
42K
  • Last Post
Replies
6
Views
9K
Replies
2
Views
2K
Replies
5
Views
22K
  • Last Post
2
Replies
29
Views
68K
Replies
2
Views
10K
Replies
2
Views
739
Replies
6
Views
6K
Replies
5
Views
4K
Top