cs_Morinaux
Messages postés34Date d'inscriptionmercredi 19 novembre 2003StatutMembreDernière intervention16 mai 2009
-
17 janv. 2008 à 18:38
cs_Morinaux
Messages postés34Date d'inscriptionmercredi 19 novembre 2003StatutMembreDernière intervention16 mai 2009
-
17 janv. 2008 à 20:36
Bonsoir,
Je souhaiterais rendre ma form transparente, mais uniquement la form et non les contrôles présent à l'intérieur.
Pour le moment j'utilise SetLayeredWindowAttributes mais ça me rend transparent tout mon programme !
Une solution ? une idée ?
Merci
A voir également:
Masquer uniquement la form et non les contrôles présent à l'intérieur
PCPT
Messages postés13272Date d'inscriptionlundi 13 décembre 2004StatutMembreDernière intervention 3 février 201847 17 janv. 2008 à 19:39
salut,
enlève la barre de titre, mets par exemple la couler magenta (&HFF00FF) à ta form, et ne choisi que l'argument COULEUR, pas ALPHA
concrêtement çà donne :
Option Explicit
Private Const GWL_EXSTYLE As Long = (-20&)
Private Const LWA_COLORKEY As Long = &H1
Private Const WS_EX_LAYERED As Long = &H80000
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 Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As
Long
'
Private Sub Form_Load()
SetWindowLong Me.hWnd, GWL_EXSTYLE, WS_EX_LAYERED
SetLayeredWindowAttributes Me.hWnd, Me.BackColor, 0, LWA_COLORKEY
End Sub
++
PCPT [AFCK]
<hr size="2" width="100%" />Prenez un instant pour répondre à [infomsg_SONDAGE-POP3-POUR-CS_769706.aspx ce sondage] svp