Semi-Visible (Ghost) Windows
Keywords: semi-transparent ghost windows semi-visible windows
Here is some really cool code to make a semi-transparent (ghost) window. It only works on Windows XP/W2K.#DefineFunction Transparent(title,visibility) Terminate("2-5-0" > WinVersion(5),"Error","Need Windows 2000/XP/++ for this code") WS_EX_LAYERED = 524288 ;&H80000 GWL_EXSTYLE = -20 LWA_ALPHA = 2 hwnd=DllHwnd(title) dllnameGDI=strcat(DirWindows(1),"GDI32.DLL") dllnameUSER=strcat(DirWindows(1),"USER32.DLL") dllnameKRNL=strcat(DirWindows(1),"KERNEL32.DLL") x=DllCall(dllnameUSER,long:"GetWindowLongA",long:hWnd,long:GWL_EXSTYLE) x=x ^ WS_EX_LAYERED DllCall(dllnameUSER,long:"SetWindowLongA",long:hWnd,long:GWL_EXSTYLE,long:x) DllCall(dllnameUSER,long:"SetLayeredWindowAttributes",long:hwnd,long:0,long:visibility,long:LWA_ALPHA) #EndFunction Run("notepad.exe","") visibility=64 ; 0 = invisible 128=50 percent visible 255=100 percent visible Transparent("~Notepad",visibility)
Article ID: W15279