Connecting Tech Pros Worldwide Forums | Help | Site Map

Adding images (bitmap) to any colum of a listview

Ivan Figueredo
Guest
 
Posts: n/a
#1: Nov 15 '05
Hi,

I have successfully implemented a simple TreeView Control
with a corresponding Listview.

I know how to assign a bitmap to the first item of a
Listview, but is it possible to add a bitmap to any column
of a Listview?

Finally, I was wondering if it is possible to have the
each row of a Listview have it's own background color. I
want to alternate each row with light green
(transparent ?) and white so as to make it easy to follow
the row from left to right(the way ledger accounting paper
is printed.) Is this possible?

Thanks,

Ivan

Dmitriy Lapshin [C# / .NET MVP]
Guest
 
Posts: n/a
#2: Nov 15 '05

re: Adding images (bitmap) to any colum of a listview


Hi Ivan,

There should be no problem with backgrounds - each SubItem has
BackgroundColor property which can be set individually. But as for bitmaps,
you'll most likely have to implement custom drawing. I have seen a good
example if this somewhere on www.codeproject.com, the sample was called
"Sorted List View" if my memory serves me well.

--
Dmitriy Lapshin [C# / .NET MVP]
X-Unity Test Studio
http://x-unity.miik.com.ua/teststudio.aspx
Bring the power of unit testing to VS .NET IDE

"Ivan Figueredo" <caseylara@yahoo.com> wrote in message
news:535301c37684$51ab0930$a401280a@phx.gbl...[color=blue]
> Hi,
>
> I have successfully implemented a simple TreeView Control
> with a corresponding Listview.
>
> I know how to assign a bitmap to the first item of a
> Listview, but is it possible to add a bitmap to any column
> of a Listview?
>
> Finally, I was wondering if it is possible to have the
> each row of a Listview have it's own background color. I
> want to alternate each row with light green
> (transparent ?) and white so as to make it easy to follow
> the row from left to right(the way ledger accounting paper
> is printed.) Is this possible?
>
> Thanks,
>
> Ivan[/color]

Ivan Figueredo
Guest
 
Posts: n/a
#3: Nov 15 '05

re: Adding images (bitmap) to any colum of a listview


Dmitriy,

That site really helped!

Thanks a million!

Ivan

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Closed Thread