Windows image viewer call

  • Thread starter Thread starter Gerard Druet
  • Start date Start date
G

Gerard Druet

Hi ,
On W2000 / XP there is a "MS image viewer "

I'd like to call it as an application from Access to odisplay *.tif
images

What is the application name to call ?

Thank you very much

Gerard Druet
 
Hi,

You can open the default application who is registered to handle the TIF
with the folowing code:

Global Const SW_SHOWNORMAL = 1

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

..................

ShellExecute Me.hwnd, "open", "somefile.tif", "", "C:\", SW_SHOWNORMAL

HTH,
Bogdan
 
Back
Top