MyEclipse Forums
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Author Message
rohit8891
Post subject: command line in java  PostPosted: Sep 10, 2012 - 10:04 AM



Joined: Sep 10, 2012
Posts: 3

how to run programs in java ...based on command line arguments ??
 
 View user's profile Send private message  
Reply with quote Back to top
rohit8891
Post subject: Re: command line in java  PostPosted: Sep 10, 2012 - 10:18 AM



Joined: Sep 10, 2012
Posts: 3

rohit8891 wrote:
how to run programs in java ...based on command line arguments ??

I mean while doing a program based on command line arguments in any text editor ...we do it by compiling the code in command prompt....and then we run it by using "java filename arg1 arg2 agr3...." ...so how to do the same in MyEclipse ??
 
 View user's profile Send private message  
Reply with quote Back to top
support-joy
Post subject:   PostPosted: Sep 10, 2012 - 10:46 AM
Registered Member
Registered Member


Joined: Feb 03, 2009
Posts: 3442

Rohit,

Right click on your java project > Run As > Run Configurations. This will list the Project name and main class under "Main" tab. Next to pass the arguments, you can click on "Arguments" tab and pass the command line arguments. Next Click on [Apply] and [Run].
It is the same as in Eclipse, refer - http://www.cs.colostate.edu/helpdocs/eclipseCommLineArgs.html

You should be all set.

_________________
Joy
MyEclipse Support
 
 View user's profile Send private message  
Reply with quote Back to top
rohit8891
Post subject: Re: command line in java  PostPosted: Sep 10, 2012 - 12:54 PM



Joined: Sep 10, 2012
Posts: 3

Thank you :)
 
 View user's profile Send private message  
Reply with quote Back to top
Display posts from previous:     
Jump to:  
All times are GMT - 6 Hours
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Powered by PNphpBB2 © 2003-2004 The PNphpBB Group
Credits