`
isiqi
  • 浏览: 16047114 次
  • 性别: Icon_minigender_1
  • 来自: 济南
社区版块
存档分类
最新评论

如何让VC的窗体变为透明

阅读更多
//=======================================
SetWindowLong(this->GetSafeHwnd(),GWL_EXSTYLE,
GetWindowLong(this->GetSafeHwnd(),GWL_EXSTYLE)^0x80000);
HINSTANCE hInst = LoadLibrary("User32.DLL"); //显式加载DLL
if(hInst)
{
typedef BOOL (WINAPI *MYFUNC)(HWND,COLORREF,BYTE,DWORD);
MYFUNC fun = NULL;
fun=(MYFUNC)GetProcAddress(hInst, "SetLayeredWindowAttributes");//取得SetLayeredWindowAttributes函数指针
if(fun)fun(this->GetSafeHwnd(),0,100,2);
FreeLibrary(hInst);
}
//=========================================
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics