Hey all, Haven't been around in a while.
Quick question. I've done some searching on google, and within this form, and haven't found an answer.
Using VB6, does anybody know if it's possible to sort a ListView by it's Tag property?
I know how to sort by any of the viewable columns, that's easy, but I can't seem to find any way to sort by tag.
Thanks,
Glenn
I have never heard of that being done. Why do you think it is possible? I could see creating a columnheader with the value from tag in it, but you already know you could do that.
Not very hard. Here's a link to an example:
http://realityripple.com/MyStuff/TagSortExample.zip
btw, the sorting method i used was a SelectionSort... I guess you could sort it using other methods, but Selections always seemed cleanest to me.
Grok:
I was just hoping it was possible. Instead, I just added a hidden column.
RealityRipple:
Thanks for that, but I was hoping to use the built in VB stuff. I'll check out your example later though.
I don't think there's an inherent function for it - instead, you could write a function that copies all the tags to an array and sort it from there.