Click here to Skip to main content
15,909,897 members
Home / Discussions / C#
   

C#

 
GeneralRe: Get Control from another form Pin
T.EDY15-Jul-07 17:39
T.EDY15-Jul-07 17:39 
AnswerRe: Get Control from another form Pin
Urs Enzler14-Jul-07 4:45
Urs Enzler14-Jul-07 4:45 
QuestionOnComm Events in MSCOMM OCX control Pin
AmarjeetSinghMatharu13-Jul-07 18:38
AmarjeetSinghMatharu13-Jul-07 18:38 
AnswerRe: OnComm Events in MSCOMM OCX control Pin
Dave Kreskowiak14-Jul-07 4:00
mveDave Kreskowiak14-Jul-07 4:00 
QuestionWin32 API? Pin
andyvm13-Jul-07 15:33
andyvm13-Jul-07 15:33 
AnswerRe: Win32 API? Pin
Ky Nam14-Jul-07 4:42
Ky Nam14-Jul-07 4:42 
Questionmore datails about flash files properties Pin
monamour13-Jul-07 15:30
monamour13-Jul-07 15:30 
Questionlistview item backcolor - XP problem [modified] Pin
Glen Harvy13-Jul-07 15:07
Glen Harvy13-Jul-07 15:07 
Hi,

Here's the code:

foreach (DataRow dr in myWebLoggerDataSet.MonitorList.Rows)
{
string name = dr["Name"].ToString();
string size = dr["FileSize"].ToString();
string colour = dr["Colour"].ToString();
string display = name +" : " +size;
string[] myItems = new string[]
{
display
};

ListViewItem lvi = new ListViewItem(myItems);
lvi.BackColor = Color.FromArgb(Convert.ToInt32(colour));
this.lvResourceMonitor.Items.Add(lvi);
}

The problem I have is that the item background color is used when debugging in W2K3 server but not when running normally on a Win XP machine. I need to manually select each item in XP to get the highlight color to take effect.

I've tried various options like redraw, giving the listview focus etc but to no effect.

Any suggestions for fixing this very frustrating issue?

Thanks.



-- modified at 5:42 Saturday 14th July, 2007
It happens on W2K3 as well. Works fine in debug mode though.

Glen Harvy

AnswerRe: listview item backcolor - XP problem Pin
martin_hughes14-Jul-07 2:50
martin_hughes14-Jul-07 2:50 
GeneralRe: listview item backcolor - XP problem Pin
Glen Harvy14-Jul-07 3:56
Glen Harvy14-Jul-07 3:56 
GeneralRe: listview item backcolor - XP problem Pin
martin_hughes14-Jul-07 4:35
martin_hughes14-Jul-07 4:35 
GeneralRe: listview item backcolor - XP problem Pin
Glen Harvy14-Jul-07 5:17
Glen Harvy14-Jul-07 5:17 
GeneralRe: listview item backcolor - XP problem Pin
martin_hughes14-Jul-07 9:51
martin_hughes14-Jul-07 9:51 
QuestionProblems with GUI class design Pin
User 665813-Jul-07 14:06
User 665813-Jul-07 14:06 
AnswerRe: Problems with GUI class design Pin
Luc Pattyn13-Jul-07 14:38
sitebuilderLuc Pattyn13-Jul-07 14:38 
GeneralRe: Problems with GUI class design Pin
User 665814-Jul-07 0:21
User 665814-Jul-07 0:21 
GeneralRe: Problems with GUI class design Pin
Luc Pattyn14-Jul-07 1:36
sitebuilderLuc Pattyn14-Jul-07 1:36 
GeneralRe: Problems with GUI class design Pin
User 665814-Jul-07 3:20
User 665814-Jul-07 3:20 
QuestionVideo Pin
Leslie Sanford13-Jul-07 11:15
Leslie Sanford13-Jul-07 11:15 
Questioncompression Pin
mkl_0713-Jul-07 10:24
mkl_0713-Jul-07 10:24 
AnswerRe: compression Pin
Paul Conrad13-Jul-07 10:31
professionalPaul Conrad13-Jul-07 10:31 
Question[How] Screen reading for automation tasks? Pin
sbscb13-Jul-07 9:59
sbscb13-Jul-07 9:59 
AnswerRe: [How] Screen reading for automation tasks? Pin
Shy Agam13-Jul-07 11:08
Shy Agam13-Jul-07 11:08 
QuestionConcating strings... Pin
Shy Agam13-Jul-07 9:13
Shy Agam13-Jul-07 9:13 
AnswerRe: Concating strings... Pin
PIEBALDconsult13-Jul-07 9:32
mvePIEBALDconsult13-Jul-07 9:32 

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.