Forums Register Login

package

+Pie Number of slices to send: Send
i have written a java package program and compiled it but could not run it...
can anyone explain me whether a package file be executed or not, because i have tried a lot of package prog but ended in vain..
+Pie Number of slices to send: Send
 

Originally posted by venkatesh badrinathan:
i have written a java package program and compiled it but could not run it...



java package program ? please,can you post your code?
+Pie Number of slices to send: Send
package a;
class prg
{

public static void main(String args[])
{
System.out.println("trying for a package");

}

}
hi this is my simple package program.
i have saved this in a folder named 'a', and i could compile this program but when i run this it shows some exceptions.
whereas when i remove the package statement the prg runs perfectly.
i could not figure out where i have went wrong. help me with this please...

+Pie Number of slices to send: Send
What commands are you using for compiling and running?
Your program will now be referred by the name a.prg
And it should be run from the parent package package.
[ August 04, 2008: Message edited by: Nabila Mohammad ]
+Pie Number of slices to send: Send
Thanks Mr.Mohammed.. i ve got that right
+Pie Number of slices to send: Send
It's Miss
This will take every ounce of my mental strength! All for a tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 1057 times.
Similar Threads
about nullPrintStream class
How to Configure Eclipse
How to create a package?
about package
package location
More...

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