How do I get a static background image in a ListView

I've got a nifty little program written in C# 2.0, that has a ListView as one of it's primary controls. It takes up some 3/4 of the form. I've got a background image in it, so it looks good on the load of the form, but when the ListView is scrolled, the image scrolls with the text. Everyone I've talked to at Microsoft about it has told me that it makes sense to have a static background image, and they aren't sure why it isn't like that, but nobody can tell me how to get it. I've even went so far as to override the paint event to give it a transparent background, and dropping an image into a control behind it, but apparently that requires a lot more know-how than I've got, because I just couldn't get it to work.

Any suggestions


Answer this question

How do I get a static background image in a ListView

  • Jure Turk

    This is by design. there isn't any way to get background image that doesn't scroll unless you manually draw the image in there. I don't know of any samples that can do this though. You will want to follow up with Windows Team at http://forums.microsoft.com/MSDN/ShowForum.aspx ForumID=120&SiteID=1 for thought on how to work with the ListView control.< xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

     

    -mark

    Program Manager

    Microsoft

    This post is provided “as-is”

     


  • How do I get a static background image in a ListView