0

Is it possible to debug a java program that is dependent on other jar files in VS2015? I have installed the java language support extension.

When I try, it basically tells me that it can't find the dependent jar files and it looks like the classpath is incorrect (from the executable name in task manager). What is the proper way to 'reference' other jar files (I added them to my reference) and/or what is the proper way to configure the project?

3
  • What you mean by "can't find the dependent jar"? Java doesn't have jar dependency. Show us you project file. Commented Sep 1, 2016 at 16:46
  • talex, my console project is dependent on other jar files. For example, I have a library, libFoo.jar, and I write a console app, barApp, that uses libFoo.jar. I can compile with libFoo.jar as a reference in VS, and I can run barApp from the command line, but when I try to debug barApp, I get an error that it can't find libFoo.jar. Commented Sep 1, 2016 at 20:51
  • @mojoker, I agree with Amber's suggestion, for VS debugging, it would have limitations more or less for Java apps in VS IDEs. Commented Sep 15, 2016 at 6:58

1 Answer 1

1

I don't think you can debug any random java program in Visual Studio 2015.

This MSDN Link says that only Android specific java files can be debugged.

Eclipse/Netbeans/Intellij are the most popular IDEs for Java. For classpath, either you can use IDE or you can put in the 'classpath' environment variable.

After setting environment variable, you will need to restart Visual Studio.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.