Copy/Paste this code line into a Module (click Insert/Module from the VB
editor's menu bar)...
Public Declare Function ShellExecute Lib "shell32.dll" _
Alias "ShellExecuteA" (ByVal hwnd As Long, _
ByVal lpOperation As String, ByVal lpFile As String, _
ByVal lpParameters As String, ByVal lpDirectory As String, _
ByVal nShowCmd As Long) As Long
You can then show a picture by specifying its full path to the ShellExecute
function as shown in this example macro...
Sub ShowPicture()
Dim FileName As String
FileName = "D:\Programming\VB Code\3.bmp"
ShellExecute Application.hwnd, "Open", FileName, "", "", vbNormalFocus
End Sub
Just change my example full path/filename assigned to the FileName variable
to the full path/filename for your picture file. Of course, you can query
the user for the filename and path if that is what you are ultimately
wanting to do.
As for your "Would it be better to just create another userform with the
image on it and then just show the form when the button is clicked?"
question... that depends on how you want the code to work... it is your
choice. One thing that may be a consideration for you is that the default
viewer can display many more picture file formats than can be done using a
UserForm's (or Image control's) Picture property.