CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    May 2009
    Posts
    23

    CButton without black border

    Hi,

    I am trying to create a button with bitmaps , like an on / off switch. Each time the user clicks the button the bitmap is changed correspondingly.

    I have used CButton::Create to create the button at run time. Here are the styles:
    Code:
    BS_BITMAP|WS_VISIBLE |WS_CHILD | BS_NOTIFY | BS_FLAT
    There is a black border aboud the button which i want to remove. I have tried using CBitmapButton, but it has the same black border around it.

    How can i remove the border around the button?

    thanks

  2. #2
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,430

    Re: CButton without black border

    I wonder why in this case you need a button at all?
    A simple static control (so called "picture" control) with the SS_NOTIFY and either SS_BITMAP or SS_ICON styles is what you need!
    Victor Nijegorodov

  3. #3
    Join Date
    May 2009
    Posts
    23

    Re: CButton without black border

    Thank you

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