ListView Tech question??? RRS feed

  • Question

  • Which forum do I need.....

    I have a Visual Studio VB application (version 8.0) with a ListView set to display large icons.

    The tile size is 201,124 and the image size which was initially 43,124 is now 63,124

    I can load images to the ImageList and then load this to the ListView, with the image showing the correct size; as I load more images, the scroll bar appears which allows me to scroll through all of the images.

    At this point, quite randomly, the images will either be of the correct size 63,124 or a narrower size closer to the original size of 43,124. When selected, a narrow image always reverts to the correct new size.

    As well as loading the images I am also loading and displaying the image name under the image. This loads correctly and always shows the full image name. The use of a tile size larger than the image size allows the displayed image name to take up more width than the actual image.

    The ImageList and the ListView are both left unsorted, with the images being sorted before being loaded to both of these objects. Also, both of these are totally cleared before a new image is added; the new sorted array is then loaded to these objects.

    I have searched the project to see if the original image size is buried somewhere in the code or the designers but cannot find it.

    Has anybody else encountered this, is it a bug, or is there somewhere that the old size may be hidden?

    Monday, March 9, 2009 8:49 AM


All replies