Click here to Skip to main content
15,913,773 members
Home / Discussions / C#
   

C#

 
AnswerRe: Unified Session Variable Pin
Ennis Ray Lynch, Jr.10-Nov-08 7:11
Ennis Ray Lynch, Jr.10-Nov-08 7:11 
GeneralAnd Pin
Ennis Ray Lynch, Jr.10-Nov-08 7:13
Ennis Ray Lynch, Jr.10-Nov-08 7:13 
GeneralRe: And Pin
k66610-Nov-08 7:23
k66610-Nov-08 7:23 
GeneralRe: And Pin
Ennis Ray Lynch, Jr.10-Nov-08 7:27
Ennis Ray Lynch, Jr.10-Nov-08 7:27 
GeneralRe: And Pin
Wendelius10-Nov-08 7:34
mentorWendelius10-Nov-08 7:34 
QuestionSave and Load problem on game of life! Pin
b3rt10-Nov-08 5:08
b3rt10-Nov-08 5:08 
AnswerCP Warning: LONG code and not using code tags Pin
leckey10-Nov-08 9:27
leckey10-Nov-08 9:27 
QuestionStrikethrough Font with Datagridview Control [modified] Pin
Paul Unsworth10-Nov-08 4:03
Paul Unsworth10-Nov-08 4:03 
Hi There.

I have an app with a Datagridview control showing an overview of jobs. Each job has a status from 0-100%.
What my boss wants me to do is set all jobs at 100% in the datagridview to strike through font. Does anybody have any idea how I can do this? Is it possible?

I have been able to locate the 100% rows and can colour the foreground and background etc, but still cannot set the Strikethrough Property. Anybody know how to do it???

Here is my code to locating the required rows...
private void OverViewColourCoding(DataGridView dg)
        {
            foreach (DataGridViewRow dgr in dg.Rows)
            {
                foreach (DataGridViewCell dgc in dgr.Cells)
                {
                    if (Convert.ToString(dgc.Value) == "100%")
                    {
                        dgr.DefaultCellStyle.ForeColor = System.Drawing.Color.Gray;
                        dgr.DefaultCellStyle.BackColor = System.Drawing.Color.LightGray;                        
                    }
                }
            }
        }


(I'm sorry if this is a simple question. I'm new to C#)

Thanks Big Grin | :-D

modified on Monday, November 10, 2008 11:36 AM

AnswerRe: Strikethrough Font with Datagridview Control Pin
Wendelius10-Nov-08 6:42
mentorWendelius10-Nov-08 6:42 
GeneralRe: Strikethrough Font with Datagridview Control Pin
Paul Unsworth10-Nov-08 21:22
Paul Unsworth10-Nov-08 21:22 
GeneralRe: Strikethrough Font with Datagridview Control Pin
Wendelius11-Nov-08 4:08
mentorWendelius11-Nov-08 4:08 
GeneralRe: Strikethrough Font with Datagridview Control Pin
Paul Unsworth11-Nov-08 5:15
Paul Unsworth11-Nov-08 5:15 
GeneralRe: Strikethrough Font with Datagridview Control Pin
Wendelius11-Nov-08 5:36
mentorWendelius11-Nov-08 5:36 
GeneralRe: Strikethrough Font with Datagridview Control Pin
Paul Unsworth12-Nov-08 2:35
Paul Unsworth12-Nov-08 2:35 
GeneralRe: Strikethrough Font with Datagridview Control Pin
Wendelius13-Nov-08 10:36
mentorWendelius13-Nov-08 10:36 
Questionfast search Pin
duta10-Nov-08 3:42
duta10-Nov-08 3:42 
AnswerRe: fast search Pin
Christian Graus10-Nov-08 3:44
protectorChristian Graus10-Nov-08 3:44 
AnswerRe: fast search Pin
Ennis Ray Lynch, Jr.10-Nov-08 4:26
Ennis Ray Lynch, Jr.10-Nov-08 4:26 
AnswerRe: fast search Pin
Wendelius10-Nov-08 6:29
mentorWendelius10-Nov-08 6:29 
AnswerRe: fast search Pin
riced10-Nov-08 7:22
riced10-Nov-08 7:22 
AnswerRe: fast search Pin
Pete O'Hanlon10-Nov-08 11:04
mvePete O'Hanlon10-Nov-08 11:04 
GeneralRe: fast search Pin
jas0n2310-Nov-08 22:23
jas0n2310-Nov-08 22:23 
AnswerRe: fast search Pin
Mark Churchill10-Nov-08 16:01
Mark Churchill10-Nov-08 16:01 
AnswerRe: fast search Pin
N a v a n e e t h10-Nov-08 16:31
N a v a n e e t h10-Nov-08 16:31 
AnswerRe: fast search Pin
Alan Balkany11-Nov-08 4:19
Alan Balkany11-Nov-08 4:19 

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.