Une des deux condition reunie pour executer mon code

Bonjour à tous
Svp J'ai un autre code que je veux exécuter si l'une des deux conditions est rempli. J’ai beau essayé mais ça ne va pas.
Voici ce que je souhaite:

1ere condition : if txtpeage= "" and txtration= "" and txtparking="" and txtmontantpayer="" and txtprixcarburant = "" and txtcarburant= "" and txtdestination="" and txtprovenance="" and txtarticle= "" and txttotalvoyage= "" and txtlisteclients="ok")

2eme condition : if TxtTotalvoyage=txtsommeqteprix

Jai besoin de votre aide svp

1 réponse

  • Votes
  • Date
  • Date décroissante
  1. Bonjour,

    Vous faites un ou entre ces deux conditions
    1. Je veux exécuter le code à condition qu'une de ces deux conditions soit rempli. Comment écrire le code?
    2. @EricRe,

      Pourtant simple:

      if 1ere condition or 2ere condition then

      If (txtpeage = "" And txtration = "" And txtparking = "" And txtmontantpayer = "" And _
          txtprixcarburant = "" And txtcarburant = "" And txtdestination = "" And txtprovenance = "" And _
          txtarticle = "" And TxtTotalvoyage = "" And txtlisteclients = "ok") Or TxtTotalvoyage = txtsommeqteprix Then    
    3. Contributeur
      @Ericpeux-tu alors marquer cette discussion comme résolue?