473,287 Members | 3,295 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,287 software developers and data experts.

activex issue - document image viewer - access 2003

Hi,

We recently built a very basic file management system for a client in
Access 2003 (to use with incoming tif scans). In it we used
Microsoft's Document Imaging activex viewer (from Office 2003). The
viewer seems to be a bit 'buggy', in that sometimes if you preview a
tif image using the activex on a form, then goto another form, and then
come back to preview the same image again on the first form, the
preview no longer shows up (just a blank box shows).

Also, I noticed that when you exit completely out of Access 2003, the
msaccess.exe process does not "close" and appears to continue to run
(doesn't show in running applications though). I started to think that
maybe the activex is forcing the access process to "hang" and not
close, when the application closes??

In VBA is there a way to reset an activex control? (like killing a
variable or object)? I did some research, but could not find an
answer, other than to reset the name of the activex object's tif image
to a blank name...

I'm thinking that maybe if we could "kill" the object or unload the
activex object, maybe that would fix both the 'preview bug', and the
issue with the process not completely closing.

Any ideas/suggestions?

Thanks!
Mike

Jul 14 '06 #1
5 6060
On 14 Jul 2006 12:18:03 -0700, "mikez" <mi*******@yahoo.comwrote:
>Hi,

We recently built a very basic file management system for a client in
Access 2003 (to use with incoming tif scans). In it we used
Microsoft's Document Imaging activex viewer (from Office 2003). The
viewer seems to be a bit 'buggy', in that sometimes if you preview a
tif image using the activex on a form, then goto another form, and then
come back to preview the same image again on the first form, the
preview no longer shows up (just a blank box shows).

Also, I noticed that when you exit completely out of Access 2003, the
msaccess.exe process does not "close" and appears to continue to run
(doesn't show in running applications though). I started to think that
maybe the activex is forcing the access process to "hang" and not
close, when the application closes??

In VBA is there a way to reset an activex control? (like killing a
variable or object)? I did some research, but could not find an
answer, other than to reset the name of the activex object's tif image
to a blank name...

I'm thinking that maybe if we could "kill" the object or unload the
activex object, maybe that would fix both the 'preview bug', and the
issue with the process not completely closing.

Any ideas/suggestions?

Thanks!
Mike
You could use the standard image control, or Steve Lebans image control, see
http://www.mcse.ms/archive147-2005-5-1640042.html

Jul 15 '06 #2
mikez wrote:
Hi,

We recently built a very basic file management system for a client in
Access 2003 (to use with incoming tif scans). In it we used
Microsoft's Document Imaging activex viewer (from Office 2003). The
viewer seems to be a bit 'buggy', in that sometimes if you preview a
tif image using the activex on a form, then goto another form, and then
come back to preview the same image again on the first form, the
preview no longer shows up (just a blank box shows).

Also, I noticed that when you exit completely out of Access 2003, the
msaccess.exe process does not "close" and appears to continue to run
(doesn't show in running applications though). I started to think that
maybe the activex is forcing the access process to "hang" and not
close, when the application closes??

In VBA is there a way to reset an activex control? (like killing a
variable or object)? I did some research, but could not find an
answer, other than to reset the name of the activex object's tif image
to a blank name...

I'm thinking that maybe if we could "kill" the object or unload the
activex object, maybe that would fix both the 'preview bug', and the
issue with the process not completely closing.

Any ideas/suggestions?

Thanks!
Mike
I use http://www.mvps.org/access/api/api0018.htm to open up registered
files and call it like
Dim var As Variant
var = fHandleFile(strAddress, 3) 'open it up maximized
I've never had a problem with this method.
Jul 15 '06 #3
I use http://www.mvps.org/access/api/api0018.htm to open up registered
files and call it like
Dim var As Variant
var = fHandleFile(strAddress, 3) 'open it up maximized
I've never had a problem with this method.
Thanks for your suggestion...

In fact, for a full preview, I am executing a shell command, per a
user's button click (which works fine). That is not the problem. The
problem is with a small "preview" image that appears on the form, via
the activex object - the first time a user "views" the tif image it
appears, but during the same session, if the user comes back to that
image, it is 'hit' or 'miss' as to whether the tif image will reappear
on the form.

But leaving the tif issue aside for a minute, has anyone ever
experienced Access 2003 "hanging"? In that the program closes, but the
application process still lingers (msaccess.exe). If you open up
Windows Taks Manager, you have to choose to "End Process" for it to
fully close. I have never experienced this before...

Thanks.
Mike

Jul 17 '06 #4
Anybody? Anyone have any further ideas or suggestions?
THanks!
mike

Jul 19 '06 #5
First I have experimented quite a bit with the control and have never had it
cause the current Access session to improperly terminate.

For your redraw issue, you can force a redaw of the control. I believe it
exposes a hWnd property.
Here is a previous post of mine on a similiar issue.

From: Stephen Lebans (NoEm...@please.com)
Subject: Re: Menu Navigation
Newsgroups: comp.databases.ms-access
View: Complete Thread (18 articles) | Original Format
Date: 2002-03-05 17:31:27 PST
This issue has come up many times in the past. What's happening is the
ListBox needs to be repainted but Access seems to have missed the
message. As you pointed out Marshall, resetting the RowSource prop
solves the issue.
There may be occasions, where because of performance considerations, you
do not want to have to reset the RowSource. In these cases we can force
the Access GUI to redraw the ListBox and clear the selection(s).
Here's a post of mine on this subject.
From: Stephen Lebans (NoEm...@please.com)
Subject: Re: How to clear data in a List box?
Newsgroups: microsoft.public.access.forms
View this article only
Date: 2001-09-16 20:43:12 PST
Hi Arvin,
just as a point of interest, I have had trouble with programmatically
clearing selections from a ListBox. It seems sometimes Access will not
redraw the ListBox unless the entire control's window needs to be
redrawn.
For the ListBoxRownumbers project on my site I had to force the
control's window to be redrawn.
http://www.lebans.com/listboxrownumbers.htm
' API Declarations for Sub to clear selections
Private Declare Function InvalidateRect Lib "user32" (ByVal hWnd&,
lpRect As RECTL, ByVal bErase&) As Long
Private Declare Function GetFocus Lib "user32" () As Long
Private Declare Function GetClientRect Lib "user32" (ByVal hWnd&, lpRect
As RECTL) As Long
Private Type RECTL
left As Long
top As Long
right As Long
bottom As Long
End Type
Private Const API_TRUE As Long = 1&
' This sub is required to eliminate a bug/feature
' in Access with ListBoxes that we programmatically select rows in.
' Access does not redraw the control unless we cover up the entire
' control. We fake this by invalidating the entire window.
' Unless you have cached the hWnd the control must have the focus for
this
' to work.
Public Sub ClearSelections(Optional hWnd As Long)
Dim rc As RECTL
' Were we passed a hWnd?
' If not then get current control's hWnd
If hWnd = 0 Then hWnd = GetFocus
Call GetClientRect(hWnd, rc)
Call InvalidateRect(hWnd, rc, API_TRUE)
End Sub
' Code End

--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
"mikez" <mi*******@yahoo.comwrote in message
news:11*********************@h48g2000cwc.googlegro ups.com...
Anybody? Anyone have any further ideas or suggestions?
THanks!
mike

Aug 1 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Shumit Rehman | last post by:
Hi I have a table which has path names to photos I would like to view. I would like to open some/any kind of image viewer(Paint) to see the picture when I click the pathname. The pictures are...
0
by: Adam Klobukowski | last post by:
Hello I have to implement a simple viewer for any type of document using ActiveX (that is any documents viewable using installed ActiveX controls). Unfortunetly anything I could find abouyt...
1
by: James | last post by:
Hello, I have developed a reporting application w/ASP.NET on IIS v5 utilizing the Crystal Reports v9 ActiveX Viewer. Another developer has produced several reports using the client version of...
3
by: Weston Fryatt | last post by:
Simple question I hope.... How do I send data to and from an ASP.Net (server side) web page to a ActiveX Control (client side) embedded in a web browser??? What I need to do, is I have image...
3
by: Weston Fryatt | last post by:
I have a custom written ActiveX Control (written in VC++ 7 unmanaged) that is embedded on a web page, I need to be able to send events (like button click and toolbar clicks) from the ActiveX...
0
by: jayender.vs | last post by:
Hello , I need to add a ActiveX control ...the Dicomviewer in ASP>net .. I am able to do it fine in C# project but not in web application I add that Dicom dll (.ocx file) in my ASP.Net form so it...
2
by: jayender.vs | last post by:
Hello , I need to add a ActiveX control ...the Dicomviewer in ASP>net .. I am able to do it fine in C# project but not in web application I add that Dicom dll (.ocx file) in my ASP.Net form so it...
0
by: jayender.vs | last post by:
Hello People, i have placed the ocx control in the web page , what i need to do is add the image in that control (Dicom Viewer) , how to do it ? is there any specific headers (like using System. ...
1
by: sop23456 | last post by:
Microsoft Access 2003 I have hyperlink the image/picture to another file. When I click on the hyperlink, the image appears using MS Paint. What do I do to view Image/picture in Windows Picture...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Aftab Ahmad | last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below. Dim IE As Object Set IE =...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.