Results 1 to 7 of 7

Thread: System.getProperty() in Java

  1. #1
    Join Date
    Jan 2010
    Posts
    119

    System.getProperty() in Java

    Hello,
    When running Java programs, this version was compiled Java byte code with a particular. This creates a dependency, the Java version on the target system needed for that, right? As it is now possible at the start of the program to check whether the installed JRE requirements of the compiled version of Java meets the? And the one custom error message will appear if the execution fails because the version and not just a cryptic error message of the JRE. Even if no Java is installed, there is probably no way to verify this platform independent, right? Something like a small program, which with System.getProperty ("java.version") determines the current version, even with Java 1.0 (?) was compiled and a class loader for all of the following classes have / use? What do you think?

  2. #2
    Join Date
    Mar 2010
    Posts
    338

    Re: System.getProperty() in Java

    An external program that is written in java not or need a command line tool (then hold for each platform), which with java-version the version reviewed one (or. Nevertheless, errors delivers when it java and thus the JRE) not found.

  3. #3
    Join Date
    Jan 2010
    Posts
    119

    Re: System.getProperty() in Java

    Thank You for the answer. Is it not a common problem? How is because normally dealt with? Come on a little lame, if someone will download your program, running, and only a cryptic error happens because the installed there VM is too old.

  4. #4
    Join Date
    Nov 2009
    Posts
    359

    Re: System.getProperty() in Java

    It's called "System", which applies everywhere and it is defined, so that potential users can clarify beforehand whether a software of its mill probably will be run on respectively. what they must do to ensure that the case is. If you are not aware of the basics of java, then I would recommend you some reading on java core and then move forward.

  5. #5
    Join Date
    Jan 2010
    Posts
    119

    Re: System.getProperty() in Java

    That may be so, but it is for the normal user, a much larger effort, in addition a VM to install (from the existing situation of absolute confusion on the sun homepage Quite apart), instead of looking only to whether sufficient RAM is available. For. NET, I feel the same in the rest.

  6. #6
    Join Date
    Jan 2010
    Posts
    311

    Re: System.getProperty() in Java

    I have a problem. The command System.getProperty ("user.dir"); gives me instead of my workspace directory, directory of my eclipse. what is this? How do I get my workspace directory instead?

  7. #7
    Join Date
    Mar 2010
    Posts
    383

    Re: System.getProperty() in Java

    You will get either a workspace directory, nor an Eclipse directory. You get exactly what is in the API documentation, namely the current working directory. I am working on the assumption that you your application directly from Eclipse (using the Run dialog), or start up. What does it say there in the "Arguments" tab (second tab) the "Working directory"?

Similar Threads

  1. Java Messaging System
    By TechGate in forum Technology & Internet
    Replies: 2
    Last Post: 28-07-2010, 05:08 PM
  2. Sun Java Desktop System
    By SoftWore in forum Technology & Internet
    Replies: 2
    Last Post: 28-07-2010, 04:11 PM
  3. How to use the System Tray in Java?
    By - Empty Shell - in forum Software Development
    Replies: 4
    Last Post: 16-02-2010, 03:50 AM
  4. Creating an operating system (OS) in Java
    By Shaan12 in forum Software Development
    Replies: 3
    Last Post: 29-10-2009, 11:51 PM
  5. Write opearting system using Java
    By Hayward in forum Software Development
    Replies: 3
    Last Post: 07-03-2009, 06:39 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •