i will paste the SRC code for every1 who wants it
NOTE: you will need 1 button and 1 text box, in the code the buttons name is: cmdTranslucent
In the code, the textbox's name is: txtTransparency
OK, first off, there are 2 modules,
OK module 1:
Code:
Option Explicit
Public Const LWA_COLORKEY = 1
Public Const LWA_ALPHA = 2
Public Const LWA_BOTH = 3
Public Const WS_EX_LAYERED = &H80000
Public Const GWL_EXSTYLE = -20
Public Declare Function SetLayeredWindowAttributes Lib "user32" (ByVal hwnd As Long, ByVal color As Long, ByVal x As Byte, ByVal alpha As Long) As Boolean
Public Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
Public Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long) As Long
Ok, now that you have that we will now move onto the second module:
Module 2:
Code:
Option Explicit
Sub SetTranslucent(ThehWnd As Long, nTrans As Integer)
On Error GoTo ErrorRtn
'SetWindowLong and SetLayeredWindowAttributes are API functions, see MSDN for details
Dim attrib As Long
attrib = GetWindowLong(ThehWnd, GWL_EXSTYLE)
SetWindowLong ThehWnd, GWL_EXSTYLE, attrib Or WS_EX_LAYERED
SetLayeredWindowAttributes ThehWnd, RGB(255, 255, 0), nTrans, LWA_ALPHA
Exit Sub
ErrorRtn:
MsgBox Err.Description & " Source : " & Err.Source
End Sub
Ok, now you have both the modules, now you need to add some more code.
this gos in the general section:
Code:
Option Explicit
Dim g_nTransparency As Integer
ok, this will be the button, make sure you redo the code or change the button name to make this code work:
Code:
Private Sub cmdTranslucent_Click()
On Error GoTo ErrorRtn
'value between 0 and 255
g_nTransparency = txtTransparency.Text
If g_nTransparency < 0 Then g_nTransparency = 0
If g_nTransparency > 255 Then g_nTransparency = 255
SetTranslucent Me.hwnd, g_nTransparency
Exit Sub
ErrorRtn:
MsgBox Err.Description & " Source : " & Err.Source
End Sub
you are almost done, now you need to add some code to the form load section of your hack.
Code:
Private Sub Form_Load()
'initialize
txtTransparency.Text = 150
g_nTransparency = 150
Me.BackColor = RGB(0, 0, 255)
End Sub
Ok, also the transparency is from 0-225
If there is any problems with the tutorial then please notify me.
If this is a bit to hard to understand, here is the project so you can study the code:
http://**********.com/files/48627982/Transparency.rar
it is rar format, and 6kb download.
edit1: for the nubs that don't know what this does, i made a screen shot >.>
[img]http://i26.photobucke*****m/albums/c143/logeyssamus/transparent.jpg[/img]
hope this helps =D