This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 52199 - [40cat] Provide action Run File with Arguments
Summary: [40cat] Provide action Run File with Arguments
Status: RESOLVED DUPLICATE of bug 49636
Alias: None
Product: java
Classification: Unclassified
Component: Project (show other bugs)
Version: 4.x
Hardware: All All
: P2 blocker with 4 votes (vote)
Assignee: Tomas Zezula
Depends on:
Reported: 2004-12-08 13:37 UTC by Milan Kubec
Modified: 2004-12-15 19:25 UTC (History)
0 users

See Also:
Exception Reporter:


Note You need to log in before you can comment on or make changes to this bug.
Description Milan Kubec 2004-12-08 13:37:48 UTC
Along with action 'Run File' there should be
action 'Run File with Arguments' that would allow
user to run selected file with arguments. Users
might have more than one main class in project for
testing purposes and it's really bad to force them
to set the class as project main class for running
it with some arguments.
Comment 1 Jiri Kovalsky 2004-12-08 14:15:48 UTC
This issue was reported through NetCAT program.
Comment 2 thunderjon 2004-12-08 18:57:30 UTC
As I had originally reported in NetCat program.


1. I have a Java application that I created in NB4.0 with only one 
class (it is a main class).

2. This class takes 2 commandline arguments. I right click the 
project name in project view->properties->running project->Arguments 
and enter my 2 commandline arguments.

3. I can then right click the project name and run project, 
everything is fine.


If I just run the file, the arguments are not passed!!!

So this is not too bad... as I can just run at the project level... 
but what if I have 2 main classes? Do I have to continually change 
the parameters at the project level and also what the project 
considers to be the main class???

This is a wicked pain as most of my classes have a main harness that 
I use during development... this seems to be slowing me down 
considerably with my console applications and libraries. 

I feel this is a very important enhancement especially for novice 
users who may not realize that arguments are not even going to the 
class they are running! Very frustrating!
Comment 3 crichey 2004-12-09 01:46:10 UTC
Agree that this needs to be fixed for 4.1 but shouldn't impact the 
release of 4.0. I also feel that it would be great to allow a user 
to create multiple "run profiles" per project / class so that you 
could easily switch between profiles containing different arguments 
for the purposes of testing.
Comment 4 Jesse Glick 2004-12-15 19:25:38 UTC

*** This issue has been marked as a duplicate of 49636 ***