Click here to Skip to main content
15,887,812 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
List<KeyValuePair<string, int>> MyValue = new List<KeyValuePair<string, int>>();
          MyValue.Add(new KeyValuePair<string, int>("Maths", 200));
          MyValue.Add(new KeyValuePair<string, int>("Physics", 136));
          MyValue.Add(new KeyValuePair<string, int>("Chemistry", 189));
          MyValue.Add(new KeyValuePair<string, int>("English", 70));
          MyValue.Add(new KeyValuePair<string, int>("Tamil", 240));
          MyValue.Add(new KeyValuePair<string, int>("kannadam", 10));

          ColumnChart1.DataContext = MyValue;




Iam using this above code to construct barchart but i want to set different color bar for each subject..please help me my coder lengends
Thanks

What I have tried:

MyValue.Add(new KeyValuePair<string, int>("Maths", 200,Colors.Red));
           MyValue.Add(new KeyValuePair<string, int>("Physics", 136,Colors.Black));


how to pass color aruguments
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900