Results 1 to 9 of 9

Thread: Win11 Style combobox usercontrol

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Nov 2011
    Posts
    695

    Win11 Style combobox usercontrol

    Hi All. I was wondering if anyone knows of a combobox usercontrol that mimics the Win11 one in looks.
    I know i can manifest but wondered if there is a usercontrol.

    tks

  2. #2
    Fanatic Member BenJones's Avatar
    Join Date
    Mar 2010
    Location
    Wales UK
    Posts
    813

    Re: Win11 Style combobox usercontrol

    have you tryed searching google. or maybe just subclass the combobox in VB and add your own drawing functions seems the best option.

    Just a qucik search in google and I found this
    https://github.com/tannerhelland/vbA...and_List_Boxes
    Last edited by BenJones; Dec 2nd, 2024 at 08:40 AM.

  3. #3
    PowerPoster
    Join Date
    Jul 2010
    Location
    NYC
    Posts
    7,037

    Re: Win11 Style combobox usercontrol

    Does VBCCR have a VisualStyles option? If not you could modify Krool's combobox control to wrap the CreateWindowEx call in a activation context (ActivateActCtx etc) so a manifest (which you can borrow from shell32.dll) is only applied to that control.

    My cTaskDialog class uses that method (see signature below). For the whole dialog, not just if there's a combobox, but the principle is the same: activate, create the window, deactivate.

    Won't it look out of place if everything doesn't have the style though?

  4. #4
    PowerPoster
    Join Date
    Feb 2017
    Posts
    5,476

    Re: Win11 Style combobox usercontrol

    As I understand the requirement, he wants a control that looks like Windows 11 themed even if it runs on other Windows versions like Windows 7.

    I don't think there is something like that there.

  5. #5
    Hyperactive Member
    Join Date
    Jul 2022
    Location
    Buford, Ga USA
    Posts
    506

    Re: Win11 Style combobox usercontrol

    There is some talk of this here https://www.vbforums.com/showthread....-style-control, of course leaning towards a roll your own. Maybe Olaf's post (#6) helps you get closer to what you'd like

  6. #6

    Thread Starter
    Fanatic Member
    Join Date
    Nov 2011
    Posts
    695

    Re: Win11 Style combobox usercontrol

    Quote Originally Posted by Eduardo- View Post
    As I understand the requirement, he wants a control that looks like Windows 11 themed even if it runs on other Windows versions like Windows 7.

    I don't think there is something like that there.
    yes that correct. a usercontrol combobox that is not manifested but still looks like the win11 version on Win7, Win10 etc

  7. #7

    Thread Starter
    Fanatic Member
    Join Date
    Nov 2011
    Posts
    695

    Re: Win11 Style combobox usercontrol

    Hi fafalone. I have Textbox usercontrol that i use that is flat and can change borders colours etc and the only control i have that looks out of place is the combobox.
    would really love to find one that can mimic the Win11 themed one without manifesting.

  8. #8
    PowerPoster
    Join Date
    Jul 2010
    Location
    NYC
    Posts
    7,037

    Re: Win11 Style combobox usercontrol

    Have you seen some of controls by Leandro Ascierto: https://leandroascierto.com/blog/cat...s-de-usuarios/

  9. #9
    Junior Member
    Join Date
    Jun 2017
    Posts
    29

    Re: Win11 Style combobox usercontrol

    I believe that's called "skinning" a control as apposed to theming it. CodeJock is an example of that type of usage.

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