Solved

DATAGRIDVIEW SELECTED ROW

Posted on 2013-06-25
4
482 Views
Last Modified: 2013-06-25
Hi All,

I have a datagridview, it has alternatingrows says :

Odd row : Black on White
Even Row : Black on Light Blue
Selected Row : White On Orange

When a row is selected, the color at Odd and Even Row are different.
I want they have the same color on selected, which is White On Orange.

How could I do it ?

Thank you.
0
Comment
Question by:emi_sastra
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 83

Expert Comment

by:CodeCruiser
ID: 39274563
>When a row is selected, the color at Odd and Even Row are different.

You mean the colour switches odd to even and even to odd? Is that above the selected row or below or both?
0
 
LVL 11

Expert Comment

by:Deepak Lakkad
ID: 39274639
Hi

see following example

http://www.dotnetperls.com/datagridview-row-colors-alternating

- Deepak Lakkad
0
 
LVL 11

Accepted Solution

by:
Deepak Lakkad earned 500 total points
ID: 39274646
Following link also has good example for setting appearance of DataGridView including Alternate rows:

http://msdn.microsoft.com/en-us/library/system.windows.forms.datagridview.alternatingrowsdefaultcellstyle.aspx
0
 
LVL 1

Author Closing Comment

by:emi_sastra
ID: 39276775
Hi deepaklakkad,

Great.

Thank you very much for your help.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to create and use a custom WaterMark textbox class.  The custom WaterMark textbox class allows you to set the WaterMark Background Color and WaterMark text at design time.   IMAGE OF WATERMARKS STEPS Create VB …
Since .Net 2.0, Visual Basic has made it easy to create a splash screen and set it via the "Splash Screen" drop down in the Project Properties.  A splash screen set in this manner is automatically created, displayed and closed by the framework itsel…
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
Suggested Courses

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question