Copier image d'un userform vers cellule
Résolu
Bob0876
Messages postés
40
Date d'inscription
Statut
Membre
Dernière intervention
-
f894009 Messages postés 17277 Date d'inscription Statut Membre Dernière intervention -
f894009 Messages postés 17277 Date d'inscription Statut Membre Dernière intervention -
A voir également:
- Copier image d'un userform vers cellule
- Comment copier une vidéo youtube - Guide
- Super copier - Télécharger - Gestion de fichiers
- Image iso - Guide
- Excel cellule couleur si condition texte - Guide
- Retrouver un copier-coller android - Guide
4 réponses
Bonjour,
inspirez vous de ceci
https://forums.commentcamarche.net/forum/affich-2328371-excel-inserer-une-image-ds-la-cellule-active
inspirez vous de ceci
https://forums.commentcamarche.net/forum/affich-2328371-excel-inserer-une-image-ds-la-cellule-active
Merci, mais malgré votre aide je ne comprend pas plus comment sectionné l'image du userform et la coller dans une cellule
voici une partie de mon code
ww = mn & 5 & aw + 3
Set b = VBA.UserForms.Add(ww)
If b.Image1.Tag <> "" Then
Workbooks("Formulaire.xlsm").Worksheets("ajdonne").Pictures.Insert(b.Image1.Tag).Select
Selection.Top = Range("k1").Top
Selection.Left = Range("k1").Left
End If
If b.Image2.Tag <> "" Then
Workbooks("Formulaire.xlsm").Worksheets("ajdonne").Pictures.Insert(b.Image2.Tag).Select
Selection.Top = Range("k25").Top
Selection.Left = Range("k25").Left
End If
Private Sub CommandButton2_Click()
(...)
Me.Image1.Picture = LoadPicture(FichImg)
Me.Image1.Tag = FichImg
(...)
end sub
ww est le nom du userform existant (vérifié)
ww = mn & 5 & aw + 3
Set b = VBA.UserForms.Add(ww)
If b.Image1.Tag <> "" Then
Workbooks("Formulaire.xlsm").Worksheets("ajdonne").Pictures.Insert(b.Image1.Tag).Select
Selection.Top = Range("k1").Top
Selection.Left = Range("k1").Left
End If
If b.Image2.Tag <> "" Then
Workbooks("Formulaire.xlsm").Worksheets("ajdonne").Pictures.Insert(b.Image2.Tag).Select
Selection.Top = Range("k25").Top
Selection.Left = Range("k25").Left
End If
Private Sub CommandButton2_Click()
(...)
Me.Image1.Picture = LoadPicture(FichImg)
Me.Image1.Tag = FichImg
(...)
end sub
ww est le nom du userform existant (vérifié)
Re,
cette partie marche sans probleme
Veuillez detailler un peu plus ce qui ne va pas !!!!!!!!!!!!!!!!!!!!
A+
cette partie marche sans probleme
Sub test()
ww = "userform2"
Set b = VBA.UserForms.Add(ww)
If b.Image1.Tag <> "" Then
Workbooks("Formulaire.xlsm").Worksheets("Accueil").Pictures.Insert(b.Image1.Tag).Select
Selection.Top = Range("k1").Top
Selection.Left = Range("k1").Left
End If
If b.Image2.Tag <> "" Then
Workbooks("Formulaire.xlsm").Worksheets("ajdonne").Pictures.Insert(b.Image2.Tag).Select
Selection.Top = Range("k25").Top
Selection.Left = Range("k25").Left
End If
End Sub
Veuillez detailler un peu plus ce qui ne va pas !!!!!!!!!!!!!!!!!!!!
A+