Thread: MFC function - ModifyStyle(), how to do this in API?

  1. #1
    Registered User
    Join Date
    Sep 2002
    Posts
    88

    MFC function - ModifyStyle(), how to do this in API?

    MFC function - ModifyStyle(), how to do this in API?

    thx,

  2. #2
    Skunkmeister Stoned_Coder's Avatar
    Join Date
    Aug 2001
    Posts
    2,572
    if you are using MFC then you have the source code for it. Have a look and see how its implemented yourself.
    Free the weed!! Class B to class C is not good enough!!
    And the FAQ is here :- http://faq.cprogramming.com/cgi-bin/smartfaq.cgi

  3. #3
    &TH of undefined behavior Fordy's Avatar
    Join Date
    Aug 2001
    Posts
    5,793
    Investigate the SetWindowLong API with the GWL_STYLE option

  4. #4
    Registered User
    Join Date
    Sep 2002
    Posts
    88
    oic, thx.

  5. #5
    Registered User
    Join Date
    Sep 2002
    Posts
    88
    excuse me , i have another qn.

    if i want to add style , i do this:
    style |= WS_BORDER ;

    how to remove style ??

  6. #6
    Skunkmeister Stoned_Coder's Avatar
    Join Date
    Aug 2001
    Posts
    2,572
    style &= ~WS_BORDER
    Free the weed!! Class B to class C is not good enough!!
    And the FAQ is here :- http://faq.cprogramming.com/cgi-bin/smartfaq.cgi

  7. #7
    Registered User
    Join Date
    Sep 2002
    Posts
    88
    thak you .

  8. #8
    Registered User
    Join Date
    Sep 2002
    Posts
    88
    i have another question:

    i have set the WS_BORDER or else already ,

    But nothing happened.

    how to make it to change to that style ??

  9. #9
    Skunkmeister Stoned_Coder's Avatar
    Join Date
    Aug 2001
    Posts
    2,572
    Try following it with a call to SetWindowPos()
    Free the weed!! Class B to class C is not good enough!!
    And the FAQ is here :- http://faq.cprogramming.com/cgi-bin/smartfaq.cgi

  10. #10
    Registered User
    Join Date
    Sep 2002
    Posts
    88
    Originally posted by Stoned_Coder
    Try following it with a call to SetWindowPos()
    thank you very much !!

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 4
    Last Post: 05-13-2011, 08:28 AM
  2. Getting an error with OpenGL: collect2: ld returned 1 exit status
    By Lorgon Jortle in forum C++ Programming
    Replies: 6
    Last Post: 05-08-2009, 08:18 PM
  3. Problem with Visual C++ Object-Oriented Programming Book.
    By GameGenie in forum C++ Programming
    Replies: 9
    Last Post: 08-29-2005, 11:21 PM
  4. OLE Clipboard :: Win32 API vs. MFC
    By kuphryn in forum Windows Programming
    Replies: 3
    Last Post: 08-11-2002, 05:57 PM
  5. Thread Synchronization :: Win32 API vs. MFC
    By kuphryn in forum Windows Programming
    Replies: 2
    Last Post: 08-09-2002, 09:09 AM