met tout ton code après ton premier IF dans la branche ELSE de celui-ci.
-------------------------------
Réponse au message :
-------------------------------
Salut !!!
je suis entrain de faire un jeu et j'ai un tit probleme!!!
Je veux unloder ma form , mais a se reload tout le temps a cause que cé dans un End..If !
Comment je résous ce problème la????
Voila ma programmation!!!
Private Sub imaDroite_Click() If auto(4).Left > 4425 Then etiCOMMENTAIRES.Caption = "BRAVO!!!!!" imaBas.Enabled = False imaGauche.Enabled = False imaDroite.Enabled = False imaHaut.Enabled = False minTemps.Enabled = False min321.Enabled = False mmBRAKE.Command = "close" mmBIP.Command = "close" frmBRAVO.Show vbModal Unload Me ' C'est ici que je veux qu'elle s'unload End If ' et elle repart ici!!! iPositionLeft = auto(num).Left iPositionTop = auto(num).Top
auto(num).Left = auto(num).Left + 1005 If num = 4 Then Else If auto(num).Left + auto(num).Width > linDroite1.X1 Then auto(num).Move iPositionLeft, iPositionTop mmBRAKE.Command = "close" mmBRAKE.Command = "open" mmBRAKE.Command = "play" End If End If
For autonum = 0 To 35 If auto(num) <> auto(autonum) Then If auto(num).Left + auto(num).Width > auto(autonum).Left + 15 And auto(num).Left + auto(num).Width < auto(autonum).Left + auto(autonum).Width + 15 And auto(num).Top + auto(num).Height / 2 > auto(autonum).Top And auto(num).Top + auto(num).Height / 2 < auto(autonum).Top + auto(autonum).Height Then ' auto(num).Move iPositionLeft, iPositionTop mmBRAKE.Command = "close" mmBRAKE.Command = "open" mmBRAKE.Command = "play" Exit For End If End If Next autonum
End Sub
|