Thread: Control-specific styles can't be applied in a resource???

  1. #1
    Registered User
    Join Date
    Jun 2008
    Posts
    161

    Control-specific styles can't be applied in a resource???

    Is it just my syntax, or is it not possible to compile a resource with styles like LVS_EX_GRIDLINES on a Listview control? I tried including commcrtl.h but it just spits out an generic compile error. Anyone else tried this?

  2. #2
    Registered User
    Join Date
    Mar 2005
    Location
    Mountaintop, Pa
    Posts
    1,058
    I've tried using LVS_EX_GRIDLINES on a ListView control in the resource file. It also does not work for me. I don't get any resource compiler errors or warnings. But the gridlines do not appear. My workaround was to use the following statement:

    Code:
     SendMessage(hList,LVM_SETEXTENDEDLISTVIEWSTYLE,0,LVS_EX_FULLROWSELECT | LVS_EX_GRIDLINES );

  3. #3
    Registered User
    Join Date
    Jun 2008
    Posts
    161
    Yeah, I use the message too. I was just hoping to remove a little clutter from the rest of my source.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Button handler
    By Nephiroth in forum Windows Programming
    Replies: 8
    Last Post: 03-12-2006, 06:23 AM
  2. Few Questions (Styles, Static Control)
    By Zeusbwr in forum Windows Programming
    Replies: 11
    Last Post: 04-15-2005, 04:13 AM
  3. Windows XP visual styles
    By larry in forum Windows Programming
    Replies: 9
    Last Post: 08-09-2003, 02:09 PM
  4. How to change control styles
    By lvk in forum Windows Programming
    Replies: 3
    Last Post: 03-03-2003, 09:56 AM
  5. Tab Controls - API
    By -KEN- in forum Windows Programming
    Replies: 7
    Last Post: 06-02-2002, 09:44 AM