Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #2  
Old 04-03-2018, 05:44 AM
p45cal's Avatar
p45cal p45cal is offline Linked Image Cannot Be Displayed Windows 10 Linked Image Cannot Be Displayed Office 2010 32bit
Expert
 
Join Date: Apr 2014
Posts: 956
p45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond repute
Default

Ditch Opic and:
Code:
Sub InsertPictures()
Dim vFilename           As Variant
Dim StartRow            As Long
Dim StartCol            As Long
Dim NumCols             As Long
Dim i                   As Long
Dim r                   As Long
Dim c                   As Long
    
vFilename = Application.GetOpenFilename( _
            FileFilter:="Pictures (*.gif;*.jpg;*.png), *.gif;*.jpg;*.png", _
            Title:="Select Picture", _
            MultiSelect:=True)
If Not IsArray(vFilename) Then Exit Sub
    
StartRow = 8
StartCol = 1
NumCols = 4
    
r = StartRow
c = StartCol
For i = LBound(vFilename) To UBound(vFilename)
  With ActiveSheet.Shapes.AddPicture(vFilename(i), Linktofile:=msoFalse, SaveWithDocument:=msoTrue, Left:=Cells(r, c).Left, Top:=Cells(r, c).Top, Width:=Cells(r, c).Width, Height:=Cells(r, c).Height)
    .LockAspectRatio = msoFalse
  End With
  If i Mod NumCols = 0 Then
    r = r + 2
    c = StartCol
  Else
    c = c + 2
  End If
Next i
End Sub
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to determine an image's linked/inserted status? Orthoducks Word 1 11-23-2016 04:00 PM
Linked Image Cannot Be Displayed how to batch update linked image files path? stanleyhuang Word 3 09-11-2014 12:51 AM
image cannot currently be displayed geddit PowerPoint 1 06-18-2012 09:26 AM
'this image cannot currently be displayed' eNGiNe Word 0 02-02-2012 07:58 AM
Linked Image automatic update? uzapuca PowerPoint 0 04-23-2011 02:03 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 05:42 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft