Jump to content
  • 0

Batch file won't run - Fixed


Question

Posted

I recently upgraded my pc to windows 7. I installed java, and minecraft, as well as technic launcher. I play technic a lot with no problem.

The issue I'm having, is when I try to run the tekkit server, I get this error:

[tt]C:\Users\User\Desktop\Tekkit server>java -Xmx3g -Xms2G -jar Tekkit.jar nogui

'java' is not recognized as an internal or external command,

operable program or batch file.

C:\Users\User\Desktop\Tekkit server>pause

Press any key to continue . . .[/tt]

How do I get around said error?

5 answers to this question

Recommended Posts

  • 0
Posted

Re: Batch file won't run

You need to either add the path to java to your %PATH% environment variable, or use the full path to java in the file you run.

I don't have Win7, so I'll let someone else tell you exactly where that is.

  • 0
Posted

Re: Batch file won't run

haha sadly enough, I suck when it comes to programs and such, so that info basically flew over my head >.< I'm trying to learn a little, but I just suck :D

  • 0
Posted

Re: Batch file won't run

ok then there is something to learn: search your pc for the java.exe file. (normaly found in Win 7 under "C:\Program Files (x86)\Java\jre6\bin") If you use java 7 then the jre7-folder instead.

On my 64bit-installation it is "C:\Program Files\Java\jre7\bin". But thats not interesting: if you find the folder just copy the path from the adressrow into the lancher.bat right in front of your java so that it looks like:

"C:\Program Files\Java\jre7\bin\java" -Xmx3G -Xms2G -jar Tekkit.jar nogui

pause

or maybe:

"C:\Program Files (x86)\Java\jre6\bin\java" -Xmx3G -Xms2G -jar Tekkit.jar nogui

pause

Don't forget the brackets. Save the new launcher.bat and it should just work like a charm.

to open the launcher.bat for editing just open it with your notepad.exe, ok?

  • 0
Posted

I did this but it didnt work it came up with a message that looked like this

Error occurred during initialization of VM

Could not reserve enough space for object heap

Could not create the java virtual machine

If you know how to fix this it would be very awesome if you would ;)

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...