Page 1 of 1

new to java and the other posts are confusing (javac.exe)

Posted: Fri Nov 21, 2003 7:15 pm
by vasastrae
Hello,

ok...Well, I tried to view all the other posts that pertained to my question and I still don't understand what's going on. My problem is that when I use TextPad and I try to compile a program...a warning appears and states

C:\WINNT\System32\javac.exe
this system cannot find the file specified

ok..I looked at all the other posts and I just understand how to correct the problem..
The thing is that I can use the Command Prompt just fine. I can compile my programs through the Command Prompt but not on TextPad..
I'm thinking it has something to do with setting the PATH but I'm confused on how to do that..the other posts were vague and catered to exprerience computer users, which i am not. I'd appreciate the help greatly! Thank you.

Posted: Fri Nov 21, 2003 10:11 pm
by talleyrand
I would assume that your registry has an entry stating that the java compiler (javac) exists in the \winnt\system3 folder. It doesn't sound like that is true, since you are seeing the missing file error. You now have a quest to find the javac.exe file. Start -> Run Type CMD in the box
type CD \
dir /b /s javac.exe
Update the java tool with that path and file

update java tool

Posted: Sat Nov 22, 2003 1:25 am
by vasastrae
C:\java\bin\javac.exe

from here....how do i update the java tool?

Posted: Sat Nov 22, 2003 2:50 pm
by bbadmin
Perhaps if you explained what you don't understand about the two answers pertaining to this problem in the Java FAQ, we could rewrite them to make them easier to understand.

Keith MacDonald
Helios Software Solutions

Posted: Sat Nov 22, 2003 6:17 pm
by vasastrae
Hello Keith,

Ok, Well, I tried those directions in the faq's and Texpad compiling still doesn't work. From this, I believe I understand the directions set forth in that section but what I don't understand is why they do not help me correct my problem.

I have windows 2000. Textpad won't compile. a warning sign appears as I have explained above. I worked on the configuration within Textpad that have been explained in other posts (i did look through those). I worked on the Environent tab Path and classpath settings that have been explained in other posts as well to no avail.

What i know: C:\java\bin\javac.ex
How do i get Textpad to find this?

thanks for all your help!

Posted: Sat Nov 22, 2003 7:32 pm
by talleyrand
I'd say delete the current Compile Java tool and create a new one.
Add Program and find the javac.exe located in c:\java\bin\javac.exe
Use $File as parameters
$FileDir as initial folder
Check Capture Output and Sound Alert.
Reg Exp as output = ^\(\(\(.[^:]\)\|\([A-Za-z]:\)\)[^:]+\):\([0-9]+\):
Registers file:1 Line:4

Posted: Sat Nov 22, 2003 7:57 pm
by vasastrae
that seemed to work...

thanks for all your help..

same problem

Posted: Sat Jan 24, 2004 11:19 pm
by jac
I found javac.exe but what do I do with it exactly??

Posted: Sat Jan 24, 2004 11:23 pm
by s_reynisson
You use it to compile java source code! ;)
Take a look at the link Helios posted above,
http://www.textpad.com/support/faq/java.html . HTH

Posted: Thu Feb 19, 2004 6:21 am
by mjonz
I realize this is a fairly late post on this topic,
but having run into this issue, I thought I'd post
the step by step instructions I pulled from the
previous posts:

(FYI: I'm running:
Windows XP Profession
TextPad 4
J2EE(TM) SDK 1.4 Developer Release

TextPad has been on my system for a while
while the SDK is a recent installation.
Most of the documentation I've read makes a point of
installing SDK(JDK) BEFORE TextPad which may have
made this a non-issue...)

In TextPad select 'Configure' from the menu bar.
In the 'Configure' pulldown menu, select 'Preferences'
In the 'Preferences' screen, select and expand the 'Tools' section
(if it is not already fully expanded)
If 'Compile Java' and/or 'Run Java Application' and/or 'Run Java Applet'
do not appear, select 'Add' => 'JDK Applications' in the right-hand pane.
Click 'Apply'
In the right-hand pane, select 'Add' => 'Program'
The 'Select a File' window appears.
Browse to the location of javac.exe
(In my case it was in C:\sun\appserver\jdk\bin)
Select the file, and click 'Open'
javac appears in the right-hand pane.
In the left-hand pane, Select 'javac' under 'Tools' at the bottom of the list.
The right-hand pane lists the preferences for javac.
Compare the entries to those of 'Compile Java' and modify the new javac
data as needed with the exception of the 'Command' entry at the top of
the pane.
Repeat with 'Run Java Applications' and 'Run Java Applets' as needed.

This is a work-around to actually resolving why the originals don't work,
but it does allow me to compile and run java.

javadoc.exe

Posted: Sat Feb 21, 2004 5:30 pm
by Joe Caffrey
My question relates to the previous question about not being able to find javac.exe file.

I can compile fine/ I want to add javadoc.exe. My question is why do I have to enter the complete path name? Javac.exe and java.exe do not have the path name, just the filename. Shouldn't I be able to do this w/ javadoc.exe.
I have Windows ME.
joe[/quote]

Posted: Sat Feb 21, 2004 8:12 pm
by s_reynisson
From the http://www.textpad.com/support/faq/java.html
How does TextPad locate the JDK programs?
TextPad looks in the registry for the following keys, which are written by the JDK installation program:

HKEY_LOCAL_MACHINE\Software\JavaSoft\Java Development Kit\CurrentVersion

Say the value is 1.3, then TextPad will look for the following value:

HKEY_LOCAL_MACHINE\Software\JavaSoft\Java Development Kit\1.3\JavaHome

If it is "C:\Java", then JAVA.EXE should be in C:\Java\bin
The question then becomes, does TP know that javadoc.exe is a JDK
program and thus use the HKLM key? My guess is that it does not.
Perhaps TP should know so for all exe files in the java bin folder.

If this is a must for you I would reccomend you post a poll in the
Enhancement Suggestions forum and see what support it gets.

Also put "C:\Program Files\Java\j2sdk1.5.0\bin" in my path variable,
added a DOS command with the parameter "javadoc.exe $file" as a
tool in TP and it works just fine.
HTH