help with compiler

Using the Java SDK with TextPad

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
caywooda
Posts: 2
Joined: Sun Jan 27, 2008 5:02 pm

help with compiler

Post by caywooda »

I am new to textpad, I am currently enrolled in a Java class an my professor had us download JavaSE before downloading textpad. After I did this I was playing around with textpad and I couldn't figure out how to run anything. When I go into configure\preferences\tools\add, there is no JDK commands option. I don't know how to get the option I need in order to compile and run my code.

PLEASE HELP!! :cry:
User avatar
Cloink
Posts: 81
Joined: Thu Sep 09, 2004 1:44 pm

Post by Cloink »

I don't develop in java, but a search of textpad's help for 'SDK' gave back just 2 hits, one of which was entitled "How to Use with the Java Development Kit".

Now I know Help in a lot of software is pitiful, but in the main, you can trust TextPad.
caywooda
Posts: 2
Joined: Sun Jan 27, 2008 5:02 pm

Post by caywooda »

I have already looked at those and neither of them helped me. I even tried reinstalling Java and then finding it under preferences again and nothing worked!
User avatar
Cloink
Posts: 81
Joined: Thu Sep 09, 2004 1:44 pm

Post by Cloink »

What do you mean by 'nothing worked'?

As I said, I don't use the SDK, so it may be a case of the blind leading the blind, but...

Configure >
....Preferences >
........Tools [bottom of left pane] >
............Add [dropdown in top right]

As I understand it, if the Java SDK is installed, the Java options appear on the 'Add' dropdown list - but the notes (in TextPad's help) advise that they will NOT appear if you have already added them into your tools yourself.

If they aren't appearing, and you haven't added any tools yourself, try uninstalling TP and re-installing.

If they still don't appear, there is also a 'very important' note near the top of the help saying the SDK *MUST* be installed using its setup program, so did you install it the way you must?

Failing all that, you can just create a tool yourself to do it. All a 'Tool' is, is a Windows DOS command. So you just need a tool to call JAVAC.EXE, JAVA.EXE or APPLETVIEWER.EXE, presumably passing the current filename using the $FileName 'tool parameter macro'. You may need to qualify the command with the directory the exe's are located in.

You will need to read TP's help to add these tools individually yourself, but if you select the option to 'Capture Output', then compile errors will be directed to the 'Tool Output' window; and you can also use the 'Regular expression to match output' to indicate how TP can find the line (and column) numbers so that when you double click a compile-error line, TP will position the source file to the correct place.

I hope this helps.
User avatar
Nicholas Jordan
Posts: 124
Joined: Mon Dec 20, 2004 12:33 am
Location: Central Texas ISO Latin-1
Contact:

Post by Nicholas Jordan »

If you ran the installer for the JDK, Textpad knows how to find it.
Post Reply