Forwarding: Android development? With c#!!

Source: Internet
Author: User

Forwarded from

Recently in the QQ technology group to see someone mention the development of Android in C #, I felt very surprised: Android is not only in Java development? When can I use C #? That group of friends told me: Mono.

Baidu a bit! Search the official website of Mono: http://xamarin.com/(English website, see this big enough)

According to my only point of English knowledge, it is good to understand some:

Mono uses C # and. NET to develop multiple platform mobile applications in the VS environment. This means that through mono, you can develop multiple platforms for mobile apps (i.e. iOS and Android). Sounds good, but it's a business process, so it's a charge. Fortunately, it has a free version of the app and never expires, and the only disadvantage is that the trial version is limited, as the official website says: "Xamarin trial software does not expire, but only allows the development and testing of iOS simulators and Android emulators." "It means that you can only run on a virtual machine. All right, that's all that's needed.

Let's start our work now.

1. First verify that our development environment exists in Visual Studio, support the latest visual STUDIO2012RC, and if so, proceed to the next step;

2. On its official website, click on the download version or visit this website directly: http://xamarin.com/trial, first fill out your personal information in Step1, including the mailbox, name, company, role (three versions: academic, Indie, Professional) Here I choose the indie. Then select Mono for Android in Step2 and then jump to the auto download page.

3. Open the Installer (the firewall may prevent it from running, point to allow), continue on the line, then the installer will download the installation package from the network and install it automatically, the installation package is about 850MB.

4. Wait silently until the installation is complete, and you are done at this time.

Now let's open up our development environment VS, when you create a new project, you find that one more template item mono for Android. Click on it and select Create an Android application on the right. Wait for it to be deployed, then click Tools

The start of the bar pops up as shown in the image on the left. This is what makes you choose the device. The display device is empty because we have not started the virtual machine at this time. So we'll point to start emulator image to run a virtual machine. This is the interface that pops up as shown on the right, because we're just going to do the test, so just click on it and confirm. (It is worth reminding that all of the virtual runtimes are very small in resolution, so we need to point to the Create new emulator images in the interface shown in the image on the right.) Pop down the image below, click on the image you need to modify the virtual machine, point to the right of the Edit button, in the bottom right of the screen will built-in the original QVGA, change to Default (WVGA800), or click the Resolution radio button to set the resolution, save. At this point, you need to refresh when you go back to the upper right interface. The virtual machine starts up, and don't be surprised why the running device is still empty, because it takes a while for the virtual machine to boot? Okay, there it is, select, confirm. Because it is the first time to start the virtual machine, so the deployment time is quite long, about 3, 4 minutes or so, then soon.

At this point our environment has been deployed, in fact, the folder structure is the same as in Java development, do not tell me you will not be Android development!!

Also remind that Resources/latout/main.axml is a layout file, open the default is the Android designer (Android Designer), if you want to edit the source file, you have to open the way to select the XML (text) editor, of course, You can also use the Souce tab of the Android designer (located under the editor) to edit, but that is not as convenient as the method above.

Wish everyone installs successfully, Android development smooth, welcome to shoot Bricks!!!!

Forwarding: Android development? With c#!!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.