Solved

Help Menu Creation

Posted on 1998-07-28
3
157 Views
Last Modified: 2010-05-03
I developed an application, along with an "owner's manual", which exists as a plain text readme file (written with Notepad). At this time, that readme is packed along with everything else needed, by the setup wizard. It is suggested that I also make that document available from the running application, under a menu "Help". I'm not sure how to do that. I created the appropriate menu, and there is the associated click procedure in the source code, empty at this time.  I expected to find something like a "help editor". Inside the click procedure, should I write code that invokes Notepad, and loads it with my readme?  What does that code look like?  Is there a better way? The books I have don't say much about this matter. Can you recommend a book that covers this topic well? - Thank you - Norm
0
Comment
Question by:normpos
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 2

Accepted Solution

by:
shchuka earned 100 total points
ID: 1467002
I recommend using ShellExecute() API function from shell32.dll (I assume you're using a 32-bit version).  You'd have something like this.

REM in the declaration section of the form
private declare function ShellExecute& alias "ShellExecuteA" (byval hwnd&,
       byval lpOperation$, byval lpFile$, byval lpParameters$, byval lpDirectory,
       byval nShowCmd&)
private const SW_SHOW as long = 5

REM in your menu_click subroutine
dim filename as string
dim directory as string

filename = app.path
if right$(filename,1)<>"\" filename = filename & "\"
filename = filename & "manual.txt"
directory = app.path
ShellExecute(thisform.hwnd,"Open",filename,"",directory,SW_SHOW)


This will check what program in windows is associated with the text files and open that program with your text file in it.

Another solution will be to simply open the file, read everything into a string variable, and then set the text property of some textbox to that string variable (you'll need obviously) a separate form or something for that.

0
 

Author Comment

by:normpos
ID: 1467003
shchuka: Thank you. I'll try your code and get back to you.  Yes, I'm using VB5.  Should have mentioned that in my original question.  What is "REM" in your code?  Remark?

Comment: "Standard" help in various applications appear to be organized into topics, and there are links within the help text to hop about from topic to topic.  Coming in cold, I had expected there would be something like a "help editor" for construction of the help contents.  In the past, I did some HTML coding once, which included links to various parts within a (very long) displayed document.  I was expecting to find some similar construct in this context.  Guess not. -- Norm
0
 

Author Comment

by:normpos
ID: 1467004
shchuka: By a wild coincedence, I ran into somebody carrying a third-party package specifically designed to build the contents of the menu "help".  This one costs $400 !! There are probably others around.  Know anything about this? - Norm
0

Featured Post

Creating Instructional Tutorials  

For Any Use & On Any Platform

Contextual Guidance at the moment of need helps your employees/users adopt software o& achieve even the most complex tasks instantly. Boost knowledge retention, software adoption & employee engagement with easy solution.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

729 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question