Une des deux condition reunie pour executer mon code

ERIC -  
yg_be Messages postés 23437 Date d'inscription   Statut Contributeur Dernière intervention   -
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

  1. f894009 Messages postés 17417 Date d'inscription   Statut Membre Dernière intervention   1 717
     
    Bonjour,

    Vous faites un ou entre ces deux conditions
    0
    1. Eric
       
      Je veux exécuter le code à condition qu'une de ces deux conditions soit rempli. Comment écrire le code?
      0
      1. f894009 Messages postés 17417 Date d'inscription   Statut Membre Dernière intervention   1 717 > Eric
         
        Re,

        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    
        0
      2. Eric > f894009 Messages postés 17417 Date d'inscription   Statut Membre Dernière intervention  
         
        Bonjour et merci pour cette solution
        0
      3. yg_be Messages postés 23437 Date d'inscription   Statut Contributeur Dernière intervention   1 588 > Eric
         
        peux-tu alors marquer cette discussion comme résolue?
        0