[]

Excel Makro
Merhaba,
Bir Excel dosyam var, bu dosyada A5' e eklediğim fotoğraf otomatik olarak aynı sayfadaki A30' a da eklensin istiyorum, bu makro ile mümkün heralde.
Bir de genel olarak excel kullanıyorum formüller fln da tamam belli seviyede ama bi' yukarısına geçemedim, makro kullanmayı bilmiyorum mesela, nasıl yaparım ?
Bir Excel dosyam var, bu dosyada A5' e eklediğim fotoğraf otomatik olarak aynı sayfadaki A30' a da eklensin istiyorum, bu makro ile mümkün heralde.
Bir de genel olarak excel kullanıyorum formüller fln da tamam belli seviyede ama bi' yukarısına geçemedim, makro kullanmayı bilmiyorum mesela, nasıl yaparım ?

- veritaslibertas
(04.03.24 11:46:02)

Sub sdfsdf()
Dim ws As Worksheet
Dim img As Picture
Set ws = ThisWorkbook.Sheets(1)
Set img = ws.Pictures("buraya resim dosyasının adını yazarsın")
If Not img Is Nothing Then
With ws.Range("A30")
img.Copy
.PasteSpecial
Application.CutCopyMode = False
End With
End If
End Sub
Dim ws As Worksheet
Dim img As Picture
Set ws = ThisWorkbook.Sheets(1)
Set img = ws.Pictures("buraya resim dosyasının adını yazarsın")
If Not img Is Nothing Then
With ws.Range("A30")
img.Copy
.PasteSpecial
Application.CutCopyMode = False
End With
End If
End Sub
- pislick0
(04.03.24 20:00:19)

resim dosyası sürekli değişir isim filan uğraşamam dersen de şunu kullan
Sub sdfsdf()
Dim ws As Worksheet
Dim img As Shape
Set ws = ThisWorkbook.Sheets(1)
For Each img In ws.Shapes
If Not Intersect(img.TopLeftCell, ws.Range("A5")) Is Nothing Then
img.Copy
ws.Range("A30").PasteSpecial
Application.CutCopyMode = False
Exit For
End If
Next img
End Sub
Sub sdfsdf()
Dim ws As Worksheet
Dim img As Shape
Set ws = ThisWorkbook.Sheets(1)
For Each img In ws.Shapes
If Not Intersect(img.TopLeftCell, ws.Range("A5")) Is Nothing Then
img.Copy
ws.Range("A30").PasteSpecial
Application.CutCopyMode = False
Exit For
End If
Next img
End Sub
- pislick0
(04.03.24 20:02:18)
1