VBA : Pb affichage image en fonction du resultat

Fermé
hope92500 - Modifié par hope92500 le 11/07/2013 à 17:44
Patrice33740 Messages postés 8556 Date d'inscription dimanche 13 juin 2010 Statut Membre Dernière intervention 2 mars 2023 - 11 juil. 2013 à 23:50
Bonjour,

J'ai une feuille qui après traitement de différents calculs doit afficher les images correspondant au résultats de ceux-ci. J'ai donc créer un VBA aprés plusieurs essais j'ai enfin trouvé le bon quand j'applique le code sur la premiere image tout fonctionne mais dés que je l'applique aux 11 autres plus rien ne va voici le code vba :
Private Sub Worksheet_Change(ByVal Target As Range)
If Target <> Range("J18") Then Exit Sub
Select Case Target
Case "": Maison12.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Maison12.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Maison12.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Maison12.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Maison12.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Maison12.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Maison12.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Maison12.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Maison12.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image1.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Maison12.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Maison12.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Maison12.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Maison12.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Maison12.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Maison12.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Maison12.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Maison12.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Maison12.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Maison12.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Maison12.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Maison12.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Maison12.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Maison12.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
If Target <> Range("J20") Then Exit Sub
Select Case Target
Case "": Maison1.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Maison1.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Maison1.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Maison1.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Maison1.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Maison1.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Maison1.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Maison1.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Maison1.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image1.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Maison1.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Maison1.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Maison1.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Maison1.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Maison1.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Maison1.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Maison1.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Maison1.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Maison1.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Maison1.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Maison1.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Maison1.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Maison1.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Maison1.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
If Target <> Range("J22") Then Exit Sub
Select Case Target
Case "": Image1.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Image1.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Image1.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Image1.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Image1.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Image1.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Image1.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Image1.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Image1.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image1.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Image1.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Image1.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Image1.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Image1.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Image1.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Image1.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Image1.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Image1.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Image1.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Image1.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Image1.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Image1.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Image1.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Image1.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
If Target <> Range("J24") Then Exit Sub
Select Case Target
Case "": Image2.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Image2.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Image2.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Image2.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Image2.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Image2.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Image2.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Image2.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Image2.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image2.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Image2.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Image2.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Image2.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Image2.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Image2.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Image2.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Image2.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Image2.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Image2.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Image2.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Image2.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Image2.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Image2.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Image2.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
If Target <> Range("J26") Then Exit Sub
Select Case Target
Case "": Image3.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Image3.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Image3.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Image3.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Image3.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Image3.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Image3.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Image3.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Image3.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image3.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Image3.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Image3.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Image3.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Image3.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Image3.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Image3.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Image3.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Image3.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Image3.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Image3.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Image3.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Image3.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Image3.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Image3.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
If Target <> Range("H20") Then Exit Sub
Select Case Target
Case "": Image4.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Image4.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Image4.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Image4.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Image4.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Image4.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Image4.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Image4.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Image4.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image4.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Image4.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Image4.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Image4.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Image4.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Image4.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Image4.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Image4.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Image4.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Image4.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Image4.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Image4.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Image4.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Image4.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Image4.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
If Target <> Range("L20") Then Exit Sub
Select Case Target
Case "": Image5.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Image5.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Image5.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Image5.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Image5.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Image5.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Image5.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Image5.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Image5.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image5.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Image5.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Image5.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Image5.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Image5.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Image5.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Image5.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Image5.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Image5.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Image5.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Image5.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Image5.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Image5.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Image5.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Image5.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
If Target <> Range("F22") Then Exit Sub
Select Case Target
Case "": Image6.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Image6.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Image6.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Image6.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Image6.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Image6.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Image6.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Image6.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Image6.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image6.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Image6.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Image6.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Image6.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Image6.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Image6.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Image6.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Image6.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Image6.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Image6.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Image6.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Image6.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Image6.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Image6.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Image6.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
If Target <> Range("H22") Then Exit Sub
Select Case Target
Case "": Image7.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Image7.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Image7.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Image7.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Image7.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Image7.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Image7.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Image7.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Image7.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image7.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Image7.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Image7.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Image7.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Image7.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Image7.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Image7.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Image7.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Image7.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Image7.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Image7.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Image7.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Image7.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Image.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Image.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
If Target <> Range("L22") Then Exit Sub
Select Case Target
Case "": Image8.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Image8.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Image8.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Image8.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Image8.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Image8.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Image8.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Image8.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Image8.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image8.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Image8.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Image8.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Image8.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Image8.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Image8.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Image8.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Image8.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Image8.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Image8.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Image8.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Image8.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Image8.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Image8.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Image8.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
If Target <> Range("N22") Then Exit Sub
Select Case Target
Case "": Image9.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Image9.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Image9.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Image9.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Image9.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Image9.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Image9.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Image9.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Image9.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image9.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Image9.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Image9.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Image9.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Image9.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Image9.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Image9.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Image9.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Image9.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Image9.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Image9.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Image9.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Image9.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Image9.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Image9.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
If Target <> Range("H24") Then Exit Sub
Select Case Target
Case "": Image10.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Image10.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Image10.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Image10.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Image10.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Image10.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Image10.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Image10.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Image10.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image10.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Image10.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Imag10e.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Imag10e.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Imag10e.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Image10.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Image10.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Image10.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Image10.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Image10.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Image10.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Image10.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Image10.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Image10.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Image10.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
If Target <> Range("L24") Then Exit Sub
Select Case Target
Case "": Image11.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "0": Image11.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
Case "1": Image11.Picture = LoadPicture("D:\Images\Tarot\1.JPG")
Case "2": Image11.Picture = LoadPicture("D:\Images\Tarot\2.JPG")
Case "3": Image11.Picture = LoadPicture("D:\Images\Tarot\3.JPG")
Case "4": Image11.Picture = LoadPicture("D:\Images\Tarot\4.JPG")
Case "5": Image11.Picture = LoadPicture("D:\Images\Tarot\5.JPG")
Case "6": Image11.Picture = LoadPicture("D:\Images\Tarot\6.JPG")
Case "7": Image11.Picture = LoadPicture("D:\Images\Tarot\7.JPG")
Case "8": Image11.Picture = LoadPicture("D:\Images\Tarot\8.JPG")
Case "9": Image11.Picture = LoadPicture("D:\Images\Tarot\9.JPG")
Case "10": Image11.Picture = LoadPicture("D:\Images\Tarot\10.JPG")
Case "11": Image11.Picture = LoadPicture("D:\Images\Tarot\11.JPG")
Case "12": Image11.Picture = LoadPicture("D:\Images\Tarot\12.JPG")
Case "13": Image11.Picture = LoadPicture("D:\Images\Tarot\13.JPG")
Case "14": Image11.Picture = LoadPicture("D:\Images\Tarot\14.JPG")
Case "15": Image11.Picture = LoadPicture("D:\Images\Tarot\15.JPG")
Case "16": Image11.Picture = LoadPicture("D:\Images\Tarot\16.JPG")
Case "17": Image11.Picture = LoadPicture("D:\Images\Tarot\17.JPG")
Case "18": Image11.Picture = LoadPicture("D:\Images\Tarot\18.JPG")
Case "19": Image11.Picture = LoadPicture("D:\Images\Tarot\19.JPG")
Case "20": Image11.Picture = LoadPicture("D:\Images\Tarot\20.JPG")
Case "21": Image11.Picture = LoadPicture("D:\Images\Tarot\21.JPG")
Case "22": Image11.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
End Select
End Sub

Et voici le fichier <link>http://sdrv.ms/12FcEmN</link>



2 réponses

Le Pingou Messages postés 12218 Date d'inscription mercredi 11 août 2004 Statut Contributeur Dernière intervention 2 décembre 2024 1 452
11 juil. 2013 à 23:45
Bonjour,
Eh bien, difficile de comprendre sans une explication !

0
Patrice33740 Messages postés 8556 Date d'inscription dimanche 13 juin 2010 Statut Membre Dernière intervention 2 mars 2023 1 779
11 juil. 2013 à 23:50
Bonjour,

Corrige ton code comme suit :
  If Target.Address(False, False) = "J18" Then
    Select Case Target
      Case "": Maison12.Picture = LoadPicture("D:\Images\Tarot\22.JPG")
      '...
    End Select
  End If
  If Target.Address(False, False) = "J20" Then
  '... 
0