473,660 Members | 2,475 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

custom listview loses item color when no item is selected

I have a custom listView that works fine. There are items that are
colored red to notify the user that there is a problem. However, if
you select one of the red items, then select space below any of the
other items, the red item turns back to default black. The only code
getting called on this is a listView_Click event. If you select any
other item, no matter what color, from the listView, the original one
that was selected stays red. Anyone have any ideas on this? I'm
thinking this is a MS bug, since no other code is being called, and
the only time we change colors on these items are when they are added
to the list (on program load), or if the item's properties are edited.
Neither of these events are happening right now.

Thanks in advance.

~Brian
Nov 16 '05 #1
2 2105
Hi Brian
i have been searching but didn't find any thing about bug that matchs your
problem , would you mind posting your code
Mohamed Mahfouz
MEA Developer Support Center
ITworx on behalf of Microsoft EMEA GTSC

Nov 16 '05 #2
Lemme see if I can rip it out and isolate it. I'd cut/paste directly
form the project, but I'm sure our customers wouldn't be too happy with
that, even though it wouldn't be giving up any info. I'll try to put
something together in the next day or so. Thanks.
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 16 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1248
by: timtos | last post by:
I just started to create my own ListView control and already have big problems... I use the following code at the moment: protected override void OnPaint(PaintEventArgs pe) { this.SuspendLayout(); if (this.View == View.Details) { Graphics g = pe.Graphics;
13
3757
by: Maheshkumar.R | last post by:
hi groups, I have placed an listview control, i want to iterate thru the control and find the clicked event items. listView2.Items.Add(fname.ToString(), i); how i can perform the iteration to find the item clicked...? and its item. thankz-- Mähésh Kumär. R
9
3041
by: Devron Blatchford | last post by:
Hi there, Just wondering if I change the back and fore colour of a listview item when the mouse hovers over it? I want to overide the default windows colour. Can someone please tell me how to do this? Thanks Devron
2
2929
by: Matt Michael | last post by:
Hi, I'm having a problem working with a listview in an application I'm writing. Currently, whenever the selectedindex changed event fires, it loads up a htmledit control, and other labels on the form, with the current information associated with the listview item. The control is called HtmlEdit and it references Microsoft.Mshtml Whenever I click on each item, it works fine, but it seems that whenever I use the up/down arrows(important)...
2
3570
by: Niels Jensen | last post by:
Hi all, I have a listview and a textbox. when I select a row in the listview I want to be able to click on the textbox and type in some details. This obviously works fine - however when I click on the textbox the selected row in the listview loses it's selection (the usual windows blue vanishes - as if no row was selected) is there any way to keep the highlight "lit" in a listview when working with other controls on a form? Thanks...
6
22142
by: George | last post by:
Hi all, How can I get the value stored from the selected item and subitems of a listview? Thanks in advance, George
6
5536
by: Brandon McCombs | last post by:
Hello, I have a form that contains a listview on the left side and a column of buttons on the right side. Only some of the buttons do I want enabled all the time. The other buttons should be enabled only if something is selected in the listview. That part specifically works but not very well. It seems that I can only get the buttons to disable if I click off the text of the items in the listview but still within about 10-20 pixels of...
6
5659
by: Rich Raffenetti | last post by:
I have a form with a listview control and a textbox. When I change focus from the listview to the textbox, the highlighted item on the listview loses the highlight. That is not the behavior I need. I am using VB2008 express. I see that the behavior of a similar program in VB6 is the same. When the controls are a listbox and a textbox, the highlighted item remains highlighted when changing focus to the textbox. So I might guess that...
4
6811
by: ari | last post by:
I have recently upgraded from vb.net 2002 to 2005, and have encountered the following problem. I have a listview with say a dozen items. Following a user action I programmatically update the background colour of the currently selected item to red. Lets say in this case it was the 3rd row. The 3rd row is still the current item, so its still got a blue background. Now in the past if I scrolled down or clicked on another row, I would...
0
8428
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8341
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8630
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6181
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5650
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4176
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4342
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2759
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1739
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.