HELP! Having Trouble Compiling my Programs

I am designing an application based solely on java, where the user is allowed to choose from a list of selected programs and then see the corresponding code in a textarea. I have my code entering into the textarea fine but when i want the code inside the textarea to compile and eventually execute, i cannot get it to work. i have the 'compile' and 'run' as buttons on my toolbar.
below i have included a web site address describing what i would like to do. It works on much the same basis except i am not using turtle graphics. i would appreciate some feedback on this, and some code would be an added bonus to tackle my problem. i have spent hours on this problem but still no further.
http://www.otherwise.com/Jurtle.html
I have also been looking at the classpath and making changes but still no luck. i have decided to include this as well as it might be the root to the problem. My programs are compiling fine in JCreator, but thats using jdk1.3.1, and as you can see from the code below i am now using jdk1.4 in JBuilder. This shouldn't cause an overlap problem should it?
Below is some of the code i have been working on:
public void jButtonCompile_actionPerformed(ActionEvent e) {
        try {
String[] execArray = new String[7];
                        String classpath = new String();
                         execArray[0] = "c:/JBuilderX/jdk1.4/bin/javac.exe";
                         execArray[1] = "-deprecation";
                         execArray[2] = "-classpath";
                        execArray[3] = classpath.toString();
                         execArray[4] = "-sourcepath";
                         execArray[5] = "c:/Thesis/lib";
                       execArray[6] = "GUIcolor.java";
                       Process p = Runtime.getRuntime().exec(execArray);
catch (IOException ex) {
            System.out.println(ex);
    }.;C:\PROGRA~1\JMF21~1.1\lib\sound.jar;C:\PROGRA~1\JMF21~1.1\lib\jmf.jar;C:\JBuilderX\jdk1.4\src.jar;C:\JBuilderX\jdk1.4\lib\tools.jar;

Give this a look:
http://www.javaworld.com/javaworld/jw-12-2000/jw-1229-traps.html
MOD

Similar Messages

  • Having trouble compiling

    I am a total newbie at programming and I am having trouble compiling. In the MS-DOS prompt, I located the folder where my .java file is located and typed the following:
    javac SampleProgram.java
    I received a "Bad command or file name" error. I am typing the names correctly. I am using Java 2 SDK, Standard Edition Version 1.3.1. Am I doing something wrong?
    Thanks for any help.

    That should fix it. The problem is that DOS needs to know where to find the executable files like javac.exe
    You can either set the path temporarily by typing
    SET PATH=.;c:\jdk1.3.1\bin
    at the command prompt each time you open a command window, or you can set it more permanently by adding it to your startup config. This will depend on your OS. On win 98 for example, there is an AUTOEXEC.BAT (usually with a SET PATH command already present). You could open this in notepad to add/change:
    SET PATH=C:\WINDOWS
    to
    SET PATH=C:\WINDOWS;.;C:\JDK1.3.1\BIN
    Reboot to make the changes take effect. Other OS's may have a special dialog to set this kind of command.
    Hope this helps some.

  • I just paid the $9,99 a month to have access to Photoshop and lightroom.  I am having trouble installing the programs and when I installed on Photoshop it said "trial"- this isn't suppose to be a trial but  a resource I pay for monthly for a year right?

    I just paid the $9,99 a month to have access to Photoshop and lightroom.  I am having trouble installing the programs and when I installed on Photoshop it said "trial"- this isn't suppose to be a trial but  a resource I pay for monthly for a year right?

    What turns the trial into the live software is signing in. If you sign in with the Adobe ID that has the subscription, the trial becomes live. First check your account on Adobe.com to make sure that the subscription is live.

  • Having trouble downloading my program

    I own an Adobe Acrobat X Pro in my account (purchased in Dec 2011).  I'm having trouble with the program on my computer and would like to download again and reinstall.  The download link on my account purchase record gives me an error "#413 - Header length too large".  Shouldn't I be able to download my program at any time?

    Lisley58 please clear your cache and cookies and try again with your current web browser.  If the problem continues then please utilize a different web browser.

  • I need to un-install then re-install my Adobe Creative Suite 6. I am having troubles with the programs.

    I need to un-install then re-install my Adobe Creative Suite 6. I am having troubles with the programs.

    Hi legates1,
    You can uninstall the software by going to Control Panel > Programs
    You can also use the Creative Suite Cleaner tool ( Use the CC Cleaner Tool to solve installation problems | CC, CS3-CS6 ) to remove the software completely.
    Regards,
    Rave

  • FDM mail app - having trouble compiling 1.6 anyone have 1.6 package??

    Hi... sorry to be writing about fdm again.
    http://aur.archlinux.org/packages.php?ID=7806
    I'm having trouble getting 1.6 installed.
    I'm still hoping that the bug fixes in the recently release update for tdb might spark an ARCH version of fdm 1.6.
    I need fdm 1.6 as the current version 1.4-1 does some weird things with gmail and it's about 16 moths old. There's been a version 1.6 since xmas.
    Anyways, sorry to be wimpering.
    Anyone have a 1.6 working?
    Last edited by yvonney (2009-03-07 09:01:54)

    I can now use ABS well enough.
    Noticed the bug repor and now that  tdb has just been updated, and, I assume the bug is gone... I'm wondering:
    - should I wait for new version 1.6 to show up?
    - If anyone has a PKGBUILD for 1.6 that will work just lke it will when the package is updated to 1.6 and in AUR.
    I think that if I were to just download the package and install I'd not only lose the pacman sync ability (wouldn't I?) and that also the locations for the files would be a bit off, and then there's that tip  I got (thanks!) about "make -j1".
    hmmm... really need the 1.6 bug fixes.
    Of course, there's lots else to do.... and I'm very patient...! hehehe
    Just loving mutt and looking forward to fdm 1.6
    um, obviously!

  • Having trouble compiling this file reader program!!

    Hi,
    I wrote this program to read a flat file so I can parse it thereafter. I'm not sure where I need to change syntax.
    If need be, I can send the error msg.
    Thanks in advance!!
    import java.io.*;
    class FileReader1
         public String readLine() throws IOException
              try {
                   //FileReader br = new FileReader(new
                   //File("C:\\Shared CLM\\netsvc.txt")) ;
                   LineNumberReader lnr = new LineNumberReader(new FileReader(
                   "C:\\Shared CLM\\netsvc.txt")) ;
                   String line = lnr.readLine() ;
                   //switch() {...}
                        lnr.close() ;
                        //br.close() ;
                   } catch (IOException e) {
                                  e.printStackTrace();
    }

    Well, I removed the ";" but I am still getting 9 errors...
    C:\mail\CLM Mail Program\Ballb.java:6: ';' expected
         public String readLine() throws IOException
    ^
    C:\mail\CLM Mail Program\Ballb.java:6: missing method body, or declare abstract
         public String readLine() throws IOException
    ^
    .\FileReader.java:7: ';' expected
    public String readLine() throws IOException
    ^
    .\FileReader.java:28: '}' expected
    ^
    .\FileReader.java:7: cannot resolve symbol
    symbol : class IOException
    location: class FileReader
    public String readLine() throws IOException
    ^
    C:\mail\CLM Mail Program\Ballb.java:13: cannot resolve symbol
    symbol : constructor FileReader (java.lang.String)
    location: class FileReader
              {LineNumberReader lnr = new LineNumberReader(new FileReader("C:\\Shared CLM\\netsvc.txt")) ;
                                                                 ^
    C:\mail\CLM Mail Program\Ballb.java:14: cannot resolve symbol
    symbol  : variable line 
    location: class Ballb
              line = lnr.readLine() ;
                    ^
    C:\mail\CLM Mail Program\Ballb.java:21: return outside method
                   return line;
                            ^
    .\FileReader.java:7: missing method body, or declare abstract
    public String readLine() throws IOException
                  ^
    9 errors                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Having trouble compiling libdrm

    checking for PTHREADSTUBS... configure: error: Package requirements (pthread-stubs) were not met:
    No package 'pthread-stubs' found
    Consider adjusting the PKG_CONFIG_PATH environment variable if you
    installed software in a non-standard prefix.
    Alternatively, you may set the environment variables PTHREADSTUBS_CFLAGS
    and PTHREADSTUBS_LIBS to avoid the need to call pkg-config.
    See the pkg-config man page for more details.
    Would anyone know how to fix this? I'm having horrible slowness with the intel driver, so i thought id compile it and see if that helps..but I get this error when trying to compile libdrm.

    uploaded pkgbuilds if you want them:
    http://konni.giev.de/intel/
    if you are lazy, there are packages as well.
    ps: those pkgbuilds are far from perfect (basically i just replaced the version in the ones from abs) but seem to work

  • Having trouble with counting program

    I made a program to count the number of lines and number of characters from an input file. My program (below) successfully does that, as far as I know. I must also call a function to count the number of occurences of a certain letter, in this case 'a'. I can compile with no errors, but when I execute, it says there is a problem at line 1961, which is the next to last character in my input file. It says it's out of bounds....??? Thanks for the help.
    import java.util.*;
    public class Count{
         public static void main(String[] args){
              Scanner keyBoard = new Scanner(System.in);
              String line;
              String totallines = "";
              int countline = 0;
              int countchar = 0;
              int totalcharacters = 0;
              int totallength = 0;
              while(keyBoard.hasNext()){
                   line = keyBoard.nextLine();
                   String lower = line.toLowerCase();
                   countline++;
                   int len = line.length();
                   totallength = totallength + len;
                   totalcharacters = totalcharacters + countchar;
                   totallines = totallines + line;          
              totallength = totallength + 1;
              System.out.println(countline);
              System.out.println(totallength);
              countChar('a', totallines, totallength);
         public static int countChar(char ch, String s, int totallength){
              int countcharacter = 0;
              for (int k = totallength-1; k >= 0; k--){
                   if (s.charAt(k) == ch){
                        countcharacter++;
              System.out.println(countcharacter);
              return countcharacter;
    }

    --...OutOfBounds exception means to indicate that an array has been accessed with an illegal index. The index is either negative or greater than or equal to the size of the array.
    --it also applies if you're goin to accessed your String.. try to double check all your loops that has an access to your strings....                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Help having trouble creating a jar file

    I managed to create the jar file but when I try to run it I get the message "Could not find the main class.Program will exit". Here are the comands i used from dos, with the results.
    C:\Documents and Settings\Levybee\My Documents\Greenwich_University\PROJECT\Tac_
    3D>echo Main-Class: Tac3D >manifest.txt
    C:\Documents and Settings\Levybee\My Documents\Greenwich_University\PROJECT\Tac_
    3D>jar -cvmf manifest.txt Tac3D.jar *.class redball.png redball2.png tac3d.png G
    ameOver.png
    added manifest
    adding: Board.class(in = 8497) (out= 4304)(deflated 49%)
    adding: highScores.class(in = 3214) (out= 1864)(deflated 42%)
    adding: highScores2.class(in = 2869) (out= 1674)(deflated 41%)
    adding: PickDragBehavior.class(in = 3931) (out= 2030)(deflated 48%)
    adding: Positions.class(in = 4032) (out= 2181)(deflated 45%)
    adding: Scor.class(in = 1645) (out= 1010)(deflated 38%)
    adding: Scores.class(in = 1384) (out= 866)(deflated 37%)
    adding: SplashScreen.class(in = 1649) (out= 1015)(deflated 38%)
    adding: sScreen.class(in = 1640) (out= 1013)(deflated 38%)
    adding: StartMenu.class(in = 2817) (out= 1619)(deflated 42%)
    adding: Tac3D.class(in = 4606) (out= 2449)(deflated 46%)
    adding: viewhighScores.class(in = 2078) (out= 1235)(deflated 40%)
    adding: ViewScores.class(in = 2646) (out= 1531)(deflated 42%)
    adding: Wrap3D.class(in = 4665) (out= 2437)(deflated 47%)
    adding: redball.png(in = 746) (out= 751)(deflated 0%)
    adding: redball2.png(in = 689) (out= 694)(deflated 0%)
    adding: tac3d.png(in = 5764) (out= 5747)(deflated 0%)
    adding: GameOver.png(in = 3419) (out= 3406)(deflated 0%)help anybody, I got to demostrate it in two days

    You MUST have a line break after the Main-Class part of your manifest.

  • For some reason I am having trouble finding the program

    I clicked Try and then It istalled stuff but at the end I could not find the program at all! It is not on my desktop or in programmes, why is this, have I done something wrong? Were could I find it ? Please help!

    It should be in the typical location.  Which operating system are you using exactly?  What Adobe software did you just install?

  • Having trouble Compiling using Textpad editor???

    Hi, I Knew to java as well as computers and I need help? I downloaded the java kit and was using textpad as a text editor and every time i tried to compile it said it couldn't find my file, even though I just finished typing it??? Even when I to run in textpad it gives me the same message it gives everyone else "exception in "main" thread etc.; What is this classpath stuff? What do i do with it? If anyone can e-mail me or post the typing and steps on the forum I will very appreciative.Thanks again for your help. e-mail is [email protected]

    I'll rephrase my description.
    For win98:
    1)Click start button
    2)Click Run and Type msconfig
    3) Select Autoexec tab and click 'New' if CLASSPATH variable is not present.
    4) For new entry key in "CLASSPATH=C:\<jdk directory>\jre\lib\rt.jar"
    * your jdk directory will either be jdk1.3 or jdk1.2
    Click Ok and Reboot
    For win2k or XP
    1)Right click on my computer icon on your desktop
    2)Select Properties
    3)Click on the advanced tab
    4)Click on environment variables
    5)Under system variables at the bottom click 'New' if CLASSPATH variable is not present
    6)For varibale name key in CLASSPATH
    7)For variable value key in C:\<jdk directory>\jre\lib\rt.jar
    * your jdk directory will either be jdk1.3 or jdk1.2
    Click ok and You do not need to reboot
    You should be able to compile your java code in textpad after completion of the appropriate steps above.

  • Having trouble compiling netmap kernel module

    Hey everyone,
    First time poster here. Hopefully this question isn't too stupid but I've been having a hard time figuring this out.
    I'm trying to install the netmap drivers for Arch. I've downloaded the header files through pacman, but the configure script for netmap spits out an error stating it requires the full kernel source.
    This is where I'm unsure of what to do. I've gone to kernel.org and downloaded this tar ball: http://mirrors.kernel.org/archlinux/sou … src.tar.gz
    I unpacked it to /usr/src/ and, as instructed in the configure script's error, I run the script with an option to point to the kernel source as such:
    ./configure --kernel-sources=/usr/src/linux/
    ********************************** ERROR **********************************
    *** Cannot find full kernel sources.
    *** We need the full kernel sources to build the netmap-enabled drivers.
    *** Please note that most distributions provide separate packages for kernel
    *** headers and sources. Once you know the path to kernel sources, you can
    *** rerun this script with the additional
    *** --kernel-sources=/path/to/sources
    *** option.
    *** If you are only interested in VALE and pipes, you can rerun the script
    *** now with the '--no-drivers' option. Hardware devices will then be accessed
    *** via a generic adapter at reduced performance."
    *** Current configuration values:
    *** kernel directory /lib/modules/3.18.6-1-ARCH/build
    *** [/usr/lib/modules/3.18.6-1-ARCH/build]
    *** linux version 31206 [3.18.6]
    *** module file netmap.ko
    *** subsystems generic monitor pipe vale
    *** no-drivers
    But it keeps giving me the same error! Did I not download the kernel source? I feel like I'm so close...
    - Cory
    Last edited by burning_flag (2015-03-19 05:28:36)

    Step by Step to fix your Mac

  • Having trouble deleting a program

    My kid downloaded a program and i can't delete it (Mackeeper)

    Uninstalling Software: The Basics
    Most OS X applications are completely self-contained "packages" that can be uninstalled by simply dragging the application to the Trash.  Applications may create preference files that are stored in the /Home/Library/Preferences/ folder.  Although they do nothing once you delete the associated application, they do take up some disk space.  If you want you can look for them in the above location and delete them, too.
    Some applications may install an uninstaller program that can be used to remove the application.  In some cases the uninstaller may be part of the application's installer, and is invoked by clicking on a Customize button that will appear during the install process.
    Some applications may install components in the /Home/Library/Applications Support/ folder.  You can also check there to see if the application has created a folder.  You can also delete the folder that's in the Applications Support folder.  Again, they don't do anything but take up disk space once the application is trashed.
    Some applications may install a startupitem or a Log In item.  Startupitems are usually installed in the /Library/StartupItems/ folder and less often in the /Home/Library/StartupItems/ folder.  Log In Items are set in the Accounts preferences.  Open System Preferences, click on the Accounts icon, then click on the LogIn Items tab.  Locate the item in the list for the application you want to remove and click on the "-" button to delete it from the list.
    Some software use startup daemons or agents that are a new feature of the OS.  Look for them in /Library/LaunchAgents/ and /Library/LaunchDaemons/ or in /Home/Library/LaunchAgents/.
    If an application installs any other files the best way to track them down is to do a Finder search using the application name or the developer name as the search term.  Unfortunately Spotlight will not look in certain folders by default.  You can modify Spotlight's behavior or use a third-party search utility, Easy Find, instead.  Download Easy Find at VersionTracker or MacUpdate.
    Some applications install a receipt in the /Library/Receipts/ folder.  Usually with the same name as the program or the developer.  The item generally has a ".pkg" extension.  Be sure you also delete this item as some programs use it to determine if it's already installed.
    There are many utilities that can uninstall applications.  Here is a selection:
    AppZapper
    Automaton
    Hazel
    CleanApp
    Yank
    SuperPop
    Uninstaller
    Spring Cleaning
    Look for them at VersionTracker or MacUpdate.
    For more information visit The XLab FAQs and read the FAQ on removing software.

  • Can any one help having trouble purchasing items within apps

    NNeed help can't purchase within apps I could before

    What happens when you try to do the IAPs, if you are getting an error message then what does it say ?
    If you are getting a message to contact iTunes Support then to do so (these are user-to-user forums) :
    - go to http://www.apple.com/support/itunes/ww
    - click on your country's flag
    - click on the Contact Support at the bottom of the left-hand column
    - click on Contact iTunes Store Support on the right-hand side of the page
    - then Purchases, Billing & Redemption
    If it's a different problem ... ?

Maybe you are looking for

  • Archiving material master

    Hello Friends, I have put deletion flag for material by MM06 & tried to execute SARA transaction, however While doing archving, iam getting the following errors in the SM37 job log after write step, please let me know how to resolve th same: 1. MARC:

  • IPhone 6 plus screen becomes unresponsive!!!

         I bought my IPhone 6 plus when released. I received it by mail on October 17. now the phone was perfect,it worked the way it should and the screen was perfect also. The only problem i had with it was that whenever i would close an app through th

  • Open File with Application in Automator - Bug???

    I have created a simple workflow to open a text file with TextEdit. It seems to work once, then subsequent times the workflow goes to the point that TextEdit opens but the file doesn't open along with it. I have encountered the same type of problem w

  • How do i get this table stuff to display in middle of browser ( page ) ?

    hiya. I used to have dreamweaver when it was macromedia. things have certainly changed since then. Now I'm using that ms expressions thing ( free now ? ) and made this http://rodneybauer.com/index.html how do I get the stuff to go to the middle of th

  • XML through HTTP send

    Hello, I am having an requirement in which another web application would send XML through HTTP request to SAP which would be processed in SAP. I was thinking to use BSP where the external web application would send HTTP request to BSP URL. I was tryi