?
Solved

Using Windows' WinHelp in Java

Posted on 1997-09-03
1
Medium Priority
?
299 Views
Last Modified: 2006-11-17
Hello,
I am a new Java programmer wanting to create a Java email application for use ONLY on the Windows platform.  I want to create as part of it a Windows help function using the  WinHelp compiler to create .hlp files.

Question:-
What is the syntax for running a context-sensitive Windows help file from within Java?

I would use the following (apparently) in C:-
WinHelp(hwnd, "c:\myapp\myhelp.hlp", HELP_COMMAND, (DWORD)(LPSTR)"JI(`',`TOPIC_2')")

which loads the indicated Help file and executes the JI() macro to jump to the topic TOPIC_2 within that Help file.

I would much appreciate the Java version of the above.

Thanks,

Trimtrom
0
Comment
Question by:trimtrom
[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
1 Comment
 
LVL 1

Accepted Solution

by:
fadl earned 200 total points
ID: 1226275
Since Java is designed as a platform independent language
and environment, every attempt to e.g.

PlatformA x PlatformB
Win* x Unix

* read directory file lists
new File("c:\documents\joe\") x  new File("/home/joe/doc")
or

* execute program
Runtime.exec("c:\windows\scandisk")   Runtime.vs exec("/bin/rm -rf /tmp/joes")

is a pletform DEPENDENT. So is your problem.

I see the only one solution
Put the C code you mentioned into Java native methods
and do sth like

if( getProperty("os.name").startsWith("Win") {
      // call you native method
      }
else{
      // new BadLuckDialog("Sorry my programs is
      // for Win users only"); {:)
}
Hope it helped
Michal
0

Featured Post

Get 15 Days FREE Full-Featured Trial

Benefit from a mission critical IT monitoring with Monitis Premium or get it FREE for your entry level monitoring needs.
-Over 200,000 users
-More than 300,000 websites monitored
-Used in 197 countries
-Recommended by 98% of users

Question has a verified solution.

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

This was posted to the Netbeans forum a Feb, 2010 and I also sent it to Verisign. Who didn't help much in my struggles to get my application signed. ------------------------- Start The idea here is to target your cell phones with the correct…
Are you developing a Java application and want to create Excel Spreadsheets? You have come to the right place, this article will describe how you can create Excel Spreadsheets from a Java Application. For the purposes of this article, I will be u…
Video by: Michael
Viewers learn about how to reduce the potential repetitiveness of coding in main by developing methods to perform specific tasks for their program. Additionally, objects are introduced for the purpose of learning how to call methods in Java. Define …
Viewers will learn about arithmetic and Boolean expressions in Java and the logical operators used to create Boolean expressions. We will cover the symbols used for arithmetic expressions and define each logical operator and how to use them in Boole…
Suggested Courses
Course of the Month13 days, 1 hour left to enroll

777 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