CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1

    Gotta Love that ListView - MultiLine and Checkbox questions

    Gotta wonder how with all these kludges there's any TreeView/ListView software written, *ever*.

    First (and big) question: How do I implement some of the functionality of, say, a Microsoft-Outlook-style ListView in my programs? The indenting, the block of text (you know, the blue one) underneath the actual list item, etc? Should I be using a third-party control? And if so, is there one that's free? I'm not cheap, I just figure that Microsoft didn't pay some guy at a software house $900 for an "Outlook-like" ListView OCX when they were writing Outlook :-). Besides the fact that at times like these, I'm sitting here wondering why I spent money *at all* on VB when all the cool stuff is in the aftermarket controls.

    Second Question: Why are there thousands of tutorials on VB sites regarding how to put checkboxes in a ListView, when all I had to do was click "Checkboxes" in the control's Custom dialog? And for that matter, why is there a similar number of webpages explaining how one selects a full row in a ListView, when all I've ever had to do was check "FullRowSelect" in the same place?

    (I'm asking in part because I'm designing my first app with checkboxes in the ListView, and I'm wondering if those 1,000 lines of code and all the API calls and the somebody-else's-code-I'm-really-never-going-to-understand is easier than the built-in method.)

    Thanks,
    Mark

    -----
    Mark D. Scudder
    (www.markscudder.com)

  2. #2
    Join Date
    Jan 2000
    Location
    MO, USA
    Posts
    1,506

    Re: Gotta Love that ListView - MultiLine and Checkbox questions

    The reason for all the other websites explaining how to put FullRowSelect-ability and Checkboxes is because, before VB6, those weren't options on the listview. It was done with API calls - some of them fairly messy at that. M$ finally figured out that we were tweaking their controls so much, that it was just easier to wrap all that stuff into a single control. When VB6 came out, they warapped all the popular API into it as well. FullRowSelect, Gridlines, checkboxes, HoverSelect and some other junk. If that had always been there, don't you think someone would have found it by now? This is the case for most of the stuff on code sites. If there is a property for it now, it's because there hasn't been for years prior. Take the ImageCombo control, for example. That's new VB6 - and if you look hard enough, you'll find some code that some poor guy slaved over for about a week to put together. now M$ just up and releases the same control - but only after they realised it would help out programmers.

    the things that M$ does in their apps aren't generally available to us for at least of couple of years. Take the flat toolbar control. IE 4 had it, Office 97 had it and VB 5 had it. But we couldn't use it until VB6. As for outlook - they probably are using some sort of custom Hiearchical Flex Grid to group those messages like that. I bet with enough cursing and beatin on the keyboard, someone here could mimic it.

    john

    John Pirkey
    MCSD
    http://www.ShallowWaterSystems.com
    http://www.stlvbug.org
    John Pirkey
    MCSD (VB6)
    http://www.stlvbug.org

  3. #3
    Join Date
    May 2001
    Posts
    1

    Re: Gotta Love that ListView - MultiLine and Checkbox questions

    If you haven't already, check out http://www.vbaccelerator.com. There are several good FREE controls there, and one of which is an outlook style grid


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured