473,413 Members | 1,705 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,413 software developers and data experts.

HtmlHelp causes error on application close

Hello

I have written some help files using Html Help Workshop version 4.74.8702

I use the following code to launch the chm file

Declare Function HtmlHelp Lib "HHCtrl.ocx" Alias "HtmlHelpA" _
(ByVal hwndCaller as long, ByVal pszFile as String, ByVal uCommand as long,
dwData as Any) as Long
Const HH_DISPLAY_TOPIC = $H0
Const HH_HELP_CONTEXT = &HF
Public Sub LaunchHelp ()

Dim hwndHelp as Long
hwndHelp = HtmlHelp(Application.hWndAccessApp, "C:\MyHelp.chm",
HH_HELP_CONTEXT, _
ByVal 1002)

End Sub
When I launch MyHelp.chm from a MSACCESS 2000 application using the code
above the help window
opens displaying the correct help topic but if I close the application with
the help window
still opened I get the following error:

(This program has performed an illegal operation and will be shut down.)
Is there something wrong with the code I am using to launch the chm?

If I open the Microsoft Access Help from the same application
and then close the application while the help window is still opened there
is no error.

Thanks
G Gerard

May 5 '07 #1
1 2817
Hi,

I found the same problem just yesterday. The article at the following
url contains the QuitHelp subroutine which when in the unload event
procedure of my menu form fixed it:

<http://groups.google.com/group/micro...al.discussion/
browse_thread/thread/f4ed440fd9868c98/ae1126acdda7b255?
lnk=st&q=conEmpStr++HH_CLOSE_ALL&rnum=1#ae1126acdd a7b255>

Public Sub QuitHelp()
' Close all Help files - No fix known - MS bug # 11005
hwndHelp = HtmlHelp(0&, HelpFileName, HH_CLOSE_ALL, ByVal 0&)
End Sub

Regards
Mark

G Gerard wrote:
Hello

I have written some help files using Html Help Workshop version 4.74.8702

I use the following code to launch the chm file

Declare Function HtmlHelp Lib "HHCtrl.ocx" Alias "HtmlHelpA" _
(ByVal hwndCaller as long, ByVal pszFile as String, ByVal uCommand as long,
dwData as Any) as Long
Const HH_DISPLAY_TOPIC = $H0
Const HH_HELP_CONTEXT = &HF
Public Sub LaunchHelp ()

Dim hwndHelp as Long
hwndHelp = HtmlHelp(Application.hWndAccessApp, "C:\MyHelp.chm",
HH_HELP_CONTEXT, _
ByVal 1002)

End Sub
When I launch MyHelp.chm from a MSACCESS 2000 application using the code
above the help window
opens displaying the correct help topic but if I close the application with
the help window
still opened I get the following error:

(This program has performed an illegal operation and will be shut down.)
Is there something wrong with the code I am using to launch the chm?

If I open the Microsoft Access Help from the same application
and then close the application while the help window is still opened there
is no error.

Thanks
G Gerard
May 13 '07 #2

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

Similar topics

7
by: Paul | last post by:
I thought this is more of an IE issue but i've had no joy on that group perhaps somebody here will have a clue. If i click a link to a web page embedded in Excel (97 OR 2000) i get the standard...
6
by: Paul Robinson | last post by:
I am developing a website in ASP that connects to a Sybase database. However, when I try to open a connection to the database the page will not load. The script does not timeout, nor the...
0
by: Mark C | last post by:
All, I have used Excel automation many times in the past without error until now. My machine has both Access 97 and XP installed but this code is written in 97 and I am using Excel XP. The code...
3
by: kris.dorey | last post by:
Hi, Ive got the following code which seems ok but when the user runs the function for a second time I get an error message stating that the mdb is in use by another process. There is still an...
0
by: Elaine | last post by:
I have a truly curious problem with HtmlHelp and Sibling Mode in Visual C++ ..Net 2003 in an MFC app. Sibling mode allows the help viewer to display on top of the app, but if the app is clicked,...
0
by: Ryan Linneman via .NET 247 | last post by:
I have a simple program to read data from a touchscreen overEthernet using a custom DLL provided by the touchscreenmanufacturer, and I want to read this data using the threadpool.When I use the...
5
by: Neil Rossi | last post by:
I have an issue with a particular ASP page on two web servers. Let's call these servers Dev1 and Beta1. Both Servers are running IIS 5, Windows 2000 SP4 with "almost" all of the latest patches. ...
6
by: DFS | last post by:
One of my systems grew exponentially - from 13mb to 43mb - after adding some 10 temp tables (with no data), a new form, and about a thousand lines of code. The .mdb has mostly table links, lots of...
9
by: timnels | last post by:
I have an issue where I have a user control that is launched into a floating form. At some point later, I allow the user to "unfloat" the user control by reparenting it on a split container in...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

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.