Why can't I use an input file as an argument?

Answered

Unless I'm doing something wrong, the program arguments box ignores any files I try to use as input.  It seems like there was a request for this to be added back in 2011 but hasn't been.  Is there a reason why it hasn't been?  

Just seems weird to have to compile outside of Intellij to test that the input file actually works

2
5 comments

Hi, Andy!

 

Are you trying to pass a file name as an argument?

Please try advices from this link:

http://stackoverflow.com/questions/32951846/run-programme-from-intellij-with-command-line-file-input

0

How does your app handle the input, as a stream or does it take the file name and opens it for reading?

If the former, please vote for https://youtrack.jetbrains.com/issue/IDEA-140121.

0
Avatar
Permanently deleted user

@Petr - the link doesn't help unfortunately.  From what I read online and this...

http://stackoverflow.com/questions/41684239/having-trouble-with-program-arguments-and-intellij/41684309#41684309

It doesn't seem like it's possible

@Serge - that's what I want yes.  Thanks

0
Avatar
Permanently deleted user

Any updates on this? I would also really appreciate being able to have all my command-line arguments written down in a txt file that is loaded by pycharm every time I run a configuration

0

This feature is available for some Run/Debug configuration types in the current IDE version. At the moment supported types for Java-based run configurations: Application, Java Scratch, JUnit, JarApplication.

-1

Please sign in to leave a comment.