Resolu: Simplification de Formule
Bonjour,
Cette formule va chercher et affiche l'image dans la colonne Q du numero qui a dans la colonne A.
Il y aurait t-il moyen de simplifier ma formule pour pas que j'aille a ecrire chaque rangé ?
Meric de votre aide!
Bonjour,
Cette formule va chercher et affiche l'image dans la colonne Q du numero qui a dans la colonne A.
Code:
Sub InsertionIMage() 'WD
Sheets("DBReportQueryView").Activate
ActiveSheet.DrawingObjects.Delete
On Error Resume Next
Range("B4").Select
Range("q2").Select
ActiveSheet.Pictures.Insert(ThisWorkbook.Path & "\Order pictures\" & Range("a2").Value & ".jpg").Select
Selection.ShapeRange.IncrementLeft 0
Selection.ShapeRange.IncrementTop 0
Selection.ShapeRange.LockAspectRatio = msoTrue
Selection.ShapeRange.Height = 95
Range("q3").Select
ActiveSheet.Pictures.Insert(ThisWorkbook.Path & "\Order pictures\" & Range("a3").Value & ".jpg").Select
Selection.ShapeRange.IncrementLeft 0
Selection.ShapeRange.IncrementTop 0
Selection.ShapeRange.LockAspectRatio = msoTrue
Selection.ShapeRange.Height = 95
Range("A1").Select
End Sub
Il y aurait t-il moyen de simplifier ma formule pour pas que j'aille a ecrire chaque rangé ?
Meric de votre aide!
Dernière édition: