1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
| 'le/les controles dont le Tag = "OUI"
'doit être visible même si en dehors de l'image de base
For Each CntrL In Me.Controls
If CntrL.Tag = "OUI" Then
'redimensionne la Form eventuellement si ce controle dépace l'image de base
'calcul du bas et de l'extrémité droite du controle
If Hauteur < CntrL.Top + CntrL.Height Then Hauteur = CntrL.Top + CntrL.Height
If Largeur < CntrL.Left + CntrL.Width Then Largeur = CntrL.Left + CntrL.Width
'verification si la Form est suffisament grande, sinon agrandit
If Hauteur > Me.ScaleHeight Then Me.Height = ScaleY(Hauteur, 3, 1) + 15 '? 15 pas trouvé pourquoi ?
If Largeur > Me.ScaleWidth Then Me.Width = ScaleX(Largeur, 3, 1)
DoEvents
'creation du masque d'opacité
Me.Line (CntrL.Left, CntrL.Top)- _
(CntrL.Left + CntrL.Width - 1, CntrL.Top + CntrL.Height - 1), 0, BF
End If
Next |
Partager