I'm trying to get the SetLayeredWindowAttributes() function to make my form semi-transparent after i've changed the parent of the form to GethWndByWinTitle("Program Manager"), but without success.
Here's the part of my code which does this:
Does anyone know how to make this work?Code:Dim DeskH As Long Dim nullRect As RECT Dim lret As Long 'Set parent of form to make it stay on bottom DeskH = GethWndByWinTitle("Program Manager") Call SetParent(frmMain.hWnd, DeskH) 'Set layered window attributes lret = GetWindowLong(frmMain.hWnd, GWL_EXSTYLE) lret = lret Or WS_EX_LAYERED SetWindowLong frmMain.hWnd, GWL_EXSTYLE, lret SetLayeredWindowAttributes hWnd, RGB(255, 0, 255), 200, LWA_COLORKEY Or LWA_ALPHA
Thanks in advance.







Reply With Quote