ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Button to open JPG (Hyperlink) (https://www.excelbanter.com/excel-worksheet-functions/161450-button-open-jpg-hyperlink.html)

Andyb

Button to open JPG (Hyperlink)
 
Hi, I've created a button in the middle of a worksheet.
(Control toolbar - Command button)

I now want it to open a hyperlink to a JPG file when clicked?

Thanks in advance

Gord Dibben

Button to open JPG (Hyperlink)
 
Sub getpic()
ActiveWorkbook.FollowHyperlink Address:="C:\yourpath\your.jpg", _
NewWindow:=True
End Sub


Gord Dibben MS Excel MVP

On Tue, 9 Oct 2007 08:01:01 -0700, AndyB
wrote:

Hi, I've created a button in the middle of a worksheet.
(Control toolbar - Command button)

I now want it to open a hyperlink to a JPG file when clicked?

Thanks in advance




All times are GMT +1. The time now is 05:41 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com