Putting Java on Your Flash Drive Bring Java Anywhere!
#17
Posted 29 May 2010 - 07:28 AM
austin101385, on 24 March 2008 - 12:42 PM, said:
I have a 250GB Western Digital External Hard Drive I'm trying to perform this with. I am on my Dell Inspiron E1505 trying to use the cmd prompt and when I type in "F:" and press [enter], and then "notepad.js.bat" and [enter] I get a message that says 'notepad.js.bat' is not recognized as an internal or external command, operable program or batch file.
Any idea what this means? Thanks
Any idea what this means? Thanks
Try opening Notepad or any other text editor like edit in the prompt itself and typing that code then saving the file as js.bat, hope this helps!
#18 Guest_David*
Posted 13 June 2010 - 05:36 PM
iNaStY v3, on 05 February 2008 - 01:43 PM, said:
Tired of installing the Java Runtime Environment on every computer you want to work on? Below is a tutorial showing how to install Java on a USB Memory Stick!
***System Requirements***
You will need a solid state USB disk drive with at least 200 MB capacity
***Step-By-Step How-To***
Before starting the steps below, plug in your USB drive and determine which drive letter it gets.
1. Start by opening your browser (which better be Firefox
) and go to Sun Microsystems and in the upper left hand corner of the screen, point your mouse to 'Java' and select (click) on 'Download the Latest JDK'
2. You will be redirected to a Java SE Downloads page, and we're interested in the first option (currently JDK 6 Update 4). Select the 'DOWNLOAD' link next to the name
3. Select the appropriate platform (should be Windows) and check the box agreeing to the License agreement
4. You will then be prompted to select the files you wish to download (I recommend the Offline Installation so you download the complete installation file and the rest of the installation process will go quicker. The other options download additional files during the installation process)
5. Download the file, saving it where you want (Desktop will do fine) and when finished, run the setup file.
6. After the installation initializes, select 'Run' and accept the License Agreement
8. Next you will be prompted to select the Directories you want to save the install files (again, the Desktop will be fine for now) then select 'OK' at the bottom of the window. At the next screen you're taken to, Click the 'Start' Button
9. After that completes (about 10 minutes or so) accept the THIRD License Agreement
NOW PAY ATTENTION AND READ 10 AND 11 BEFORE CONTINUING
10. You will be taken to a 'Custom Setup' screen, allowing you to select the program features you want installed. Technically, the only one you actually need is the first option, 'Development Tools'. The other items listed below aren't needed and you can install them if you want.
11. Now, in that SAME WINDOW in the bottom right hand corner you'll see 'Change...' Select that and change the destination folder to your USB drive, and \jdk6 (or whatever you want to name the folder, I called it \Java)
IF YOU DON'T DO THIS JAVA WON'T INSTALL ON YOUR USB
12. When done, click 'Next' and let it install! (this will take some time)
***Set Up Your USB***
1. Open a DOS command window (either START -> Programs -> Accessories -> CommandPrompt or just START -> Run -> cmd)
2. In cmd, type k: and press enter (replace k: with the letter for your USB drive)
3.Type notepad.js.bat and press enter. A notepad window will appear. Click 'Yes' to create a new file
4. Type the following line into the notepad window:
replacing \jdk6 to whatever you named the folder in Step 11 above
5. Save the file and exit notepad
6. In the DOS window, type js and press enter (js is for java startup)
7. To see if the installation went ok, type javac . You should get a list of compiler options.
***THE INSTALLATION IS NOW COMPLETE!***
Please let me know if anyone has problems with this
***System Requirements***
You will need a solid state USB disk drive with at least 200 MB capacity
***Step-By-Step How-To***
Before starting the steps below, plug in your USB drive and determine which drive letter it gets.
1. Start by opening your browser (which better be Firefox
2. You will be redirected to a Java SE Downloads page, and we're interested in the first option (currently JDK 6 Update 4). Select the 'DOWNLOAD' link next to the name
3. Select the appropriate platform (should be Windows) and check the box agreeing to the License agreement
4. You will then be prompted to select the files you wish to download (I recommend the Offline Installation so you download the complete installation file and the rest of the installation process will go quicker. The other options download additional files during the installation process)
5. Download the file, saving it where you want (Desktop will do fine) and when finished, run the setup file.
6. After the installation initializes, select 'Run' and accept the License Agreement
8. Next you will be prompted to select the Directories you want to save the install files (again, the Desktop will be fine for now) then select 'OK' at the bottom of the window. At the next screen you're taken to, Click the 'Start' Button
9. After that completes (about 10 minutes or so) accept the THIRD License Agreement
NOW PAY ATTENTION AND READ 10 AND 11 BEFORE CONTINUING
10. You will be taken to a 'Custom Setup' screen, allowing you to select the program features you want installed. Technically, the only one you actually need is the first option, 'Development Tools'. The other items listed below aren't needed and you can install them if you want.
11. Now, in that SAME WINDOW in the bottom right hand corner you'll see 'Change...' Select that and change the destination folder to your USB drive, and \jdk6 (or whatever you want to name the folder, I called it \Java)
IF YOU DON'T DO THIS JAVA WON'T INSTALL ON YOUR USB
12. When done, click 'Next' and let it install! (this will take some time)
***Set Up Your USB***
1. Open a DOS command window (either START -> Programs -> Accessories -> CommandPrompt or just START -> Run -> cmd)
2. In cmd, type k: and press enter (replace k: with the letter for your USB drive)
3.Type notepad.js.bat and press enter. A notepad window will appear. Click 'Yes' to create a new file
4. Type the following line into the notepad window:
set Path=\jdk6\bin;%Path%
replacing \jdk6 to whatever you named the folder in Step 11 above
5. Save the file and exit notepad
6. In the DOS window, type js and press enter (js is for java startup)
7. To see if the installation went ok, type javac . You should get a list of compiler options.
***THE INSTALLATION IS NOW COMPLETE!***
Please let me know if anyone has problems with this
#19 Guest_David*
Posted 13 June 2010 - 05:41 PM
Also, sometimes this needs a small tweak, I have found that this works as well, since you never know what drive letter your flash drive will be using on every computer. This is my setup:
Install jdk to \java
on the root of the flash drive create a batch file (ex: JavaPath.bat)
inside it put this:
set PATH=%CD%\java\bin\;%PATH%
now run it from cmd.exe and you get (for example on this computer my flash drive is F: so ) F:\java\bin\; and then the rest of your path env variable.
this worked for me because it adds your entire drives path + java path to the path environment variable
Install jdk to \java
on the root of the flash drive create a batch file (ex: JavaPath.bat)
inside it put this:
set PATH=%CD%\java\bin\;%PATH%
now run it from cmd.exe and you get (for example on this computer my flash drive is F: so ) F:\java\bin\; and then the rest of your path env variable.
this worked for me because it adds your entire drives path + java path to the path environment variable
|
|






MultiQuote




|