用CWnd类的ModifyStyle函数CWnd::ModifyStyle
BOOL ModifyStyle( DWORD dwRemove, DWORD dwAdd, UINT nFlags = 0 );Return Value Nonzero if style was successfully modified; otherwise, 0.ParametersdwRemove
Specifies window styles to be removed during style modification.dwAdd
Specifies window styles to be added during style modification.nFlags
Flags to be passed to SetWindowPos, or zero if SetWindowPos should not be called. The default is zero. See the Res section for a list of preset flags.或者用API中的SetWindowLongLONG SetWindowLong(
HWND hWnd, // handle of window
int nIndex, // offset of value to set
LONG dwNewLong // new value
);
具体用法你可以查MSDN
BOOL ModifyStyle( DWORD dwRemove, DWORD dwAdd, UINT nFlags = 0 );Return Value Nonzero if style was successfully modified; otherwise, 0.ParametersdwRemove
Specifies window styles to be removed during style modification.dwAdd
Specifies window styles to be added during style modification.nFlags
Flags to be passed to SetWindowPos, or zero if SetWindowPos should not be called. The default is zero. See the Res section for a list of preset flags.或者用API中的SetWindowLongLONG SetWindowLong(
HWND hWnd, // handle of window
int nIndex, // offset of value to set
LONG dwNewLong // new value
);
具体用法你可以查MSDN
解决方案 »
- error LNK2001: unresolved external symbol "int PortNum" (?PortNum@@3HA)
- C++,用GDI+画半透明图片的问题
- 如何使CListCtrl控件中每列显示宽度一样?
- 如何 编写 API 钩子??????????????????????
- 请教一个简单的问题!如何实现在文本框输入后,自动跳到下一个文本框!
- 问一个关于WindowPro的问题————》100分相送
- L和J在一起怎么设计一个LOGO?
- 怎样解决这两个问题
- 请问自己创建的CEdit控件怎样才能有一个3D的边框呢?
- ★★★请大家讲讲CAsyncSocket类虚拟函数ConnectHelper的含义和用法。
- 一个菜问题
- virtual的析构函数中delete *p1,被子类重载后,子类析构只用delete *p2,则p1是否被delete?
DWORD dwRemove,
DWORD dwAdd,
UINT nFlags = 0
);
Parameters
dwRemove
Specifies window styles to be removed during style modification.
dwAdd
Specifies window styles to be added during style modification.
nFlags
Flags to be passed to SetWindowPos, or zero if SetWindowPos should not be called. The default is zero. See the Res section for a list of preset flags. BOOL ModifyStyleEx(
DWORD dwRemove,
DWORD dwAdd,
UINT nFlags = 0
);
Parameters
dwRemove
Specifies extended styles to be removed during style modification.
dwAdd
Specifies extended styles to be added during style modification.
nFlags
Flags to be passed to SetWindowPos, or zero if SetWindowPos should not be called. The default is zero. See the Res section for a list of preset flags.
Return Value
{
ModifyStyle(WS_CAPTION,NULL,SWP_NOMOVE);
m_bMain=FALSE;
}
else
{
ModifyStyle(NULL,WS_CAPTION,SWP_NOMOVE);
m_bMain=TRUE;
}
我写了函数,但是title仍然有,只是无效,那位高手帮我看看代码,谢谢
{
ModifyStyle(WS_CAPTION,0,SWP_DRAWFRAME);
m_bMain=FALSE;
}
else
{
ModifyStyle(0,WS_CAPTION,SWP_DRAWFRAME);
m_bMain=TRUE;
}
搞定.