[dba-Tech] Windows XP - Windows Picture and FaxViewer-Nameand path of the exe file

MartyConnelly martyconnelly at shaw.ca
Sat Dec 4 17:00:21 CST 2004


Haven't had a chance to play around with this yet but with Office 2003 
there is a new control called MODI
Microsoft Office Document Imaging , it might have been available in 
Office XP but  without an exposed API.
I believe it is a free license but then my legal advice is worth what 
you pay for it.
It will display Tiff images and do OCR under mdivwctl.dll and mdivwctl.oca
I haven't seen much documentation or code  on this.

The Microsoft Office Document Imaging 2003 (MODI) Viewer OCX Control can 
be used to display images and perform minor image editing functions. 
Viewing functionality includes panning, scrolling, zooming and selecting 
both image data and text (OCR has to be performed first).

Referencing the MODI Viewer OCX Control in a Microsoft Visual Basic Project

To include the Microsoft Office Document Imaging 2003 (MODI) Viewer OCX 
Control into a Microsoft Visual Basic project, use the Project | 
Components menu item and select Microsoft Office Document Imaging 11.0 
Type Library (mdivwctl.oca). By including the Viewer OCX Control into 
the project, a reference is automatically added - making the entire 
Object Model available to the programmer. Note that the Viewer OCX 
Control corresponds to the MiDocView Object in the Microsoft Office 
Document Imaging 2003 (MODI) Object Model.
For info on API

Office 2003 Editions: VBA Language Reference for the Document Imaging 
Object Model
This download contains the Visual Basic® for Applications (VBA) Language 
Reference for the Microsoft® Office 2003 Document Imaging Object Model 
as a compiled Help file. Install chm file to the directory it selects, 
to preserve internal links but uncheck the overwrite box just in case.

http://www.microsoft.com/downloads/details.aspx?familyid=7b6d9193-a1c8-4934-8007-47089fde37de&displaylang=en
by the way here is the download page for all the vba object reference 
help files if you want Office 2003 help offline
http://msdn.microsoft.com/office/downloads/vba/default.aspx

or VB info
http://www.ilixis.com/developer/modi.html


A.D.Tejpal wrote:

>    Thanks Gustav! I greatly appreciate your help.
>
>A.D.Tejpal
>--------------
>
>  ----- Original Message ----- 
>  From: Gustav Brock 
>  To: dba-tech at databaseadvisors.com 
>  Sent: Saturday, December 04, 2004 20:04
>  Subject: Re: [dba-Tech] Windows XP - Windows Picture and FaxViewer-Nameand path of the exe file
>
>
>  Hi A.D.
>
>  I'm no API expert, but you can modify the code like this to maximize
>  ..:
>
>  <code>
>
>  Public Function ShowImage( _
>    ByVal strFile As String, _
>    Optional ByVal booMaximized As Boolean) _
>    As Long
>    
>  ' strFile must be either a directory or a file; wildcards are not
>  accepted.
>
>    Const cstrCommand   As String = "rundll32.exe shimgvw.dll,
>  ImageView_Fullscreen"
>    
>    Dim lngResult       As Long
>    Dim intWindowStyle  As Long
>    
>    If booMaximized = True Then
>      intWindowStyle = vbMaximizedFocus
>    Else
>      intWindowStyle = vbNormalFocus
>    End If
>
>    lngResult = Shell(cstrCommand & " " & strFile & "", intWindowStyle)
>
>    ShowImage = lngResult
>
>  End Function
>
>  </code>
>
>  However, it only works one way. If you have opened a picture maximized, all subsequent calls of the function will open a maximized view. You have to manually restore the view before closing it.
>  This behaviour is probably saved in the registry. You could reset that setting before calling the function.
>
>  /gustav
>
>  >>> adtp at touchtelindia.net 04-12-2004 05:14:57 >>>
>
>  Hello Gustav,
>
>      Thanks for the cross-check. 
>
>      Another question - could you possibly suggest any API call that could force the currently active display into full screen mode, irrespective of the parent application involved?
>
>      This can be useful in view of the fact that the combination of key strokes required to do it in different applications, is not always the
>  same. 
>
>  A.D.Tejpal
>  --------------
>
>_______________________________________________
>dba-Tech mailing list
>dba-Tech at databaseadvisors.com
>http://databaseadvisors.com/mailman/listinfo/dba-tech
>Website: http://www.databaseadvisors.com
>
>  
>

-- 
Marty Connelly
Victoria, B.C.
Canada






More information about the dba-Tech mailing list