Monday, June 4, 2012

How can I use MS Visual Studio for Android Development?

Can you use Visual Studio for Android Development?

If so how would you set the android SDK instead of .NET framework and are there any special settings or configuration?

Source: Tips4all


  1. Mono for Android (Press Release)

  2. Yes you can:

    In case you get "Unable to locate tools.jar. Expected to find it in C:\Program Files (x86)\Java\jre6\lib\tools.jar" you can add an environment variable JAVA_HOME that points to your Java JDK path, for example c:\sdks\glassfish3\jdk (restart MSVC afterwards)

    An even better solution is using WinGDB Mobile Edition in Visual Studio: it lets you create and debug Android projects all inside Visual Studio:

    Download WinGDC for Android from

  3. If you're interested in producing HTML5 hybrid applications (web apps wrapped in a native container giving access to device functions), the Nomad Visual Studio extension supports building for android devices.

  4. From the Android documentation:

    The recommended way to develop an Android application is to use Eclipse with the ADT plugin... However, if you'd rather develop your application in another IDE, such as IntelliJ, or in a basic editor, such as Emacs, you can do that instead.

    Currently, there are plug-ins for IntelliJ IDEA and NetBeans, but you can still use the tools in /tools to build, debug, monitor, measure and start the emulator.

  5. Believe me, I've tried so hard to find a decent IDE for Android developement but I failed. I used Visual Studio for many years, and it is so hard for me to get use to the way Eclipse doing things.

    However, the new IntelliJ supports for Android development, it's the closest you can get.

  6. I completely agree. I am a native to developing in VS, and moving to an IDE like Eclipse is a hard step, but im learning its a necessary one. I have reasons for wanting to us VS to do my development, but not because im delusional enough to think that its superior. Yes, in most cases, it does alot of the miniscule stuff for you, plugins arent hard to setup, and if your already used to how to use it, its nice. So, having VS as an IDE for Android would be great, but im not saying its better by any means. Now, if anyone knows how to get VS to develop for Java, please reply and let me know.

  7. Besides, you can use VS for Android development too, because in the end, the IDE is nothing but a fancy text editor with shortcuts to command line tools, so most popular IDE's can be used.

    However, if you want to develop fully native without restrictions, you'll have all kinds of issues, such as those related to file system case insensitivity and missing libraries on Windows platform..

    If you try to build windows mobile apps on Linux platform, you'll have bigger problems than other way around, but still makes most sense to use Linux with Eclipse for Android OS.

  8. I suppose you can open Java files in Visual Studio and just use the command line tools directly. I don't think you'd get syntax highlighting or autocompletion though.

    Eclipse is really not all that different from Visual Studio, and there are a lot of tools that are designed to make Android development more comfortable that work from within Eclipse.