Board index » cppbuilder » C++ equivalent of this Delphi line
Albert Wiersch
![]() CBuilder Developer |
Albert Wiersch
![]() CBuilder Developer |
C++ equivalent of this Delphi line2007-03-21 02:07:51 AM cppbuilder98 What is the C++ equivalent for the Delphi line: Params.ExStyle := Params.ExStyle and not WS_EX_TOOLWINDOW or WS_EX_APPWINDOW; Is it Params.ExStyle=Params.ExStyle & !WS_EX_TOOLWINDOW | WS_EX_APPWINDOW; or Params.ExStyle=Params.ExStyle & ~WS_EX_TOOLWINDOW | WS_EX_APPWINDOW; Just want to make sure. Thanks. -- Albert Wiersch |
Alex Bakaev [TeamB]
![]() CBuilder Developer |
2007-03-21 02:54:59 AM
Re:C++ equivalent of this Delphi line
Albert Wiersch wrote:
QuoteParams.ExStyle=Params.ExStyle & ~WS_EX_TOOLWINDOW | WS_EX_APPWINDOW; |
Remy Lebeau (TeamB)
![]() CBuilder Developer |
2007-03-21 04:50:15 AM
Re:C++ equivalent of this Delphi line
"Albert Wiersch" < XXXX@XXXXX.COM >wrote in message
QuoteWhat is the C++ equivalent for the Delphi line: Params.ExStyle = Params.ExStyle & ~(WS_EX_TOOLWINDOW | WS_EX_APPWINDOW); Or: Params.ExStyle &= ~(WS_EX_TOOLWINDOW | WS_EX_APPWINDOW); On the other hand, if you are trying to remove one style and add the other, then it would be the following instead: Params.ExStyle = (Params.ExStyle & ~WS_EX_TOOLWINDOW) | WS_EX_APPWINDOW; Gambit {smallsort} |
Sam
![]() CBuilder Developer |
2007-03-22 06:17:42 AM
Re:C++ equivalent of this Delphi line
Remy Lebeau (TeamB) wrote:
Quote"Albert Wiersch" < XXXX@XXXXX.COM >wrote in message -- Please remove "sam_" from email address. |
Remy Lebeau (TeamB)
![]() CBuilder Developer |
2007-03-22 09:17:21 AM
Re:C++ equivalent of this Delphi line
"Sam" < XXXX@XXXXX.COM >wrote in message
QuoteI'm not shure that this will work if Params.ExStyle is a property. |
Albert Wiersch
![]() CBuilder Developer |
2007-03-26 05:35:15 AM
Re:C++ equivalent of this Delphi line
Thanks all. I am now using this:
Params.ExStyle = (Params.ExStyle & ~WS_EX_TOOLWINDOW) | WS_EX_APPWINDOW; I want to remove WS_EX_TOOLWINDOW and add WS_EX_APPWINDOW. The Delphi "not" was confusing to me as I thought it might be "!" in C but in this case it should be "~". -- Albert Wiersch "Remy Lebeau (TeamB)" < XXXX@XXXXX.COM >wrote in message Quote
|
Remy Lebeau (TeamB)
![]() CBuilder Developer |
2007-03-26 06:58:24 AM
Re:C++ equivalent of this Delphi line
"Albert Wiersch" < XXXX@XXXXX.COM >wrote in message
QuoteThe Delphi "not" was confusing to me as I thought it might be "!" in while not Terminated do while( !Terminated ) Quotein this case it should be "~". Gambit |