关于VB窗体以及上面的控件如何设置成半透明
Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As LongPrivate Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long) As Long
Private Declare Function SetLayeredWindowAttributes Lib "user32" (ByVal hwnd As Long, ByVal crKey As Long, ByVal bAlpha As Byte, ByVal dwFlags As Long) As Long
Private Const gwl_exstyle = -20
Private Const lwa_alpha As Long = &H2
Private Const ws_ex_layered As Long = &H8000
Private Sub Form_Load()
Dim Fattri As Long
Call SetWindowLong(Me.hwnd, gwl_exstyle, Fattri Or ws_ex_layered)
Call SetLayeredWindowAttributes(Me.hwnd, 0, 200, lwa_alpha)
End Sub
以上是半透明的代码,但是窗体发生了镜像,哪位高手给指点下。该如何设置?