Results 1 to 2 of 2
  1. #1
    2 Star Lounger
    Join Date
    Mar 2001
    Location
    San Clemente, California, USA
    Posts
    130
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Pictures from Hyperlink (2002)

    Hello,

    I have the following fomula in column D

    =HYPERLINK("c:documents and settingsraymy documentsstarframersimagesebay"&A2&".jpg")

    This way I can click on the images and see them. Is there anyway to actually show the picture in Excel (either in another cell or in the column D)

    Thanks!

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Pictures from Hyperlink (2002)

    You could create code in the worksheet module:

    Private Sub Worksheet_Change(ByVal Target As Range)
    Dim oCell As Range
    Dim shp As Shape
    Const strPath = "c:documents and settingsraymy documentsstarframersimagesebay"
    If Not Intersect(Target, Range("A2:A100")) Is Nothing Then
    Application.EnableEvents = False
    On Error Resume Next
    For Each oCell In Intersect(Target, Range("A2:A100"))
    For Each shp In Me.Shapes
    If shp.Top = oCell.Offset(0, 3).Top And _
    shp.Left = oCell.Offset(0, 3).Left Then
    shp.Delete
    Exit For
    End If
    Next shp
    Me.Shapes.AddPicture Filename:=strPath & oCell & ".jpg", _
    LinkToFile:=True, SaveWithDocument:=False, _
    Top:=oCell.Offset(0, 3).Top, Left:=oCell.Offset(0, 3).Left, _
    Width:=oCell.Offset(0, 3).Width, Height:=oCell.Offset(0, 3).Height
    Next oCell
    Application.EnableEvents = True
    End If
    End Sub

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •