Forums Register Login

Java On DOS Platform : Urgent

+Pie Number of slices to send: Send
Hi everybody,

I want to know that when we create a java file it has extension .java and the class file generated is .class
But DOS only supports 3 characters as extension. What if wanna write and runa an application on DOS alone.
It's very urgent. Plz help
Neeraj
+Pie Number of slices to send: Send
i am not sure but try it!
there is a dos editor.
try:
edit File_Name.java
i repeat try it coz i don't know if it works
but this is a simple idea to try !
good luck
plz inform me if it works.
byez
+Pie Number of slices to send: Send
Hi Amer,
Got ur reply but friend when u save a file in DOS Editor it will truncate the last chars after 3 chars
so the file saved will be file.jav and not file.java and forget about the .class file.
I hope it is like this only. just check it out.
Bye
Neeraj
+Pie Number of slices to send: Send
Neeraj,
are you running a DOS only PC or are you running DOS under some version of windows? You may find that your DOS version will support long filenames but the DOS Editor will not. In that case, you can save your file and then copy or rename it back to the .java extention that you need for compliation.
+Pie Number of slices to send: Send
What version of DOS are you using? I currently compile and run Java on Win95, Win98 and WinNT at various times. I don't use an IDE - just raw DOS and notepad to save and execute from. There is no problem with the .java or .class extensions.
+Pie Number of slices to send: Send
Hi,
Thanks for the reply.
When u compile ur program from DOS PROMPT in Win 95/98/NT then there is no problem.
The reason the MSDOS PROPMPT is an application that simulates DOS and as Win 95/98/NT support long file names so does the DOS PRMPT so don't confuse the DOS PROMPT Application with DOS which is an OS.
Let me put it more clearly I have a system with only DOS installed on it there is no Win95/98/NT. How do I execute Java Programs there.
Forget about the DOS Editor that renaming can be done but what if ur OS doesn't allow more than 3 chars as Extension.
I hope I have made it clear.
Neeraj
+Pie Number of slices to send: Send
Hey Neeraj,
After you compile to .class file. Just rename it to .cls

Thanks
Angela
+Pie Number of slices to send: Send
Just out of curiosity -- why are you writing java programs in dos?
+Pie Number of slices to send: Send
He can't compile it if he's using dos 6.x or earlier though. Javac only takes a file with an extension of .java, correct? Even .jav doesn't work..
This looks like a job for .... legal tender! It says so right in this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 1069 times.
Similar Threads
:confused: Info reqd for jsdk installation: urgent
Urgent !
Urgent
Urgent on static
Plz.. reply as soon as poosible urgent
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 05:31:58.