This afternoon when learning about Android development, when learning to develop a GridView in the documentation, debug the program on the emulator everything is OK, as shown in:However, when the bin directory under the hellogridview.apk copy to the M8 Android installation, there is a "parsing package error" prompt, after the online search for answers, after the comparison with the previous example, found t
= "Android. Permission. modify_audio_settings" /> Uses-Permission Android: Name = "Android. Permission. read_contacts" /> Uses-Permission Android: Name = "Android. Permission. write_contacts" /> Uses-Permission An
Http://hi.baidu.com/fountainblog/blog/item/0dc1af7e714d9c210dd7dade.html
Version control is an important part in the process of program upgrade/maintenance.You need to know the version of the application installed on the device and the versions that can be upgraded. Other applications-including other programs you release-need to query the system for the version of your application to determine the compatibility between them. You may also need to query the version of the Service released by you
activities in xml are android: configChanges = "keyboardHidden | orientation" and some are android: configChanges = "keyboardHidden | orientation | screenSize ", the latter will show the switching screen and will not reload the corresponding resource files. The activity is not restarted (it is said that, starting from Android 3.2 (API level 13), "screen size" al
-support-multidex.jar to the project from the sdk \ extras \ android \ support \ multidex \ library \ libs directory
2. If your project already contains the Application class, let it inherit the android. support. multidex. MultiDexApplication class,
If your Application has inherited other classes and does not want to modify them, there is another way to overwrite the attachBaseContext () method:
public cl
In Android development, you will need to configure the minimum and target versions of the Android SDK using the app, which is the Bulidl.gradle Android module setting. The following settings are available by default:
ApplicationID, which is the app's package name, must be unique in the Google App Store and cannot be modified throughout the app's lifecycle,
First, understand the Android operating system
Android was first founded by Andy Robin (Andy Rubin) and was acquired by Google in 2007, and Google has achieved great success with its Android operating system on smartphones.
1, the characteristics of the Android operating system
The
Android SDK Android NDK android Studio officialIf the download speed is too slow, please use thunder, Baidu cloud offline and other methods to download.For Linux systems, if you cannot upgrade online, see belowsudo vi/etc/hostsAdd to74.125.206.93 dl-ssl.google.comHere are the various.
2014.7ADT BundleHttp://dl.google.com/
, open "File"-"Setting"-"IDE Settings"-"Plugins", right click "Browse repositories", in the pop-up search box input genymotion, Locate and install the plugin;Method Two: Genymotion official download the installation package on the page there is an idea Plugins East, download, repeat the above "open Android-studio, open" File "-" Setting "-" IDE Settings "-" Plugins " ", click" Install Plugin from disk "on the right.After restarting
. This includes the Android framework, class library, and self-developed code.
This problem can be solved by splitting a DEX file into multiple DEX files.
2. subcontract policy implementation
Gradle Configuration:
defaultConfig { applicationId "XXX" minSdkVersion 14 targetSdkVersion 23 multiDexEnabled true}.......dependencies { compile 'com.android.support:multidex:1.0.0'}
In the Application
the previous versions of the last few platform APIs.Specify Minimum and Target API levelsSpecifying the minimum and target API levels--------------------------------------------------------------------------------The Androidmanifest.xml file describes details about your app and identifies which versions of Android it supports. Specifically, the minsdkversion and Targetsdkversion attributes for the The Andr
can update your plugin to the latest version (update the plugin to the latest version) or disable Crashlytics in the Debug version (disable Crashlytics for Your debug build variant).Limitations of Instant run (limitations of Instant Run)In most cases, the Instant run was developed to speed up the build and deployment. However, there are some aspects that may affect their behavior and compatibility with the program when using instant run. If you have any problems with instant run, please submit
project:For the creation of the project, I will directly translate the official website document below:It's easier to use Android studio to create an L Developer Preview project.In the initial creation interface:1. Select Phone and Tablet2. Select API 20+: Android L (Preview) in Minimum SDK.Once created, open the Build.gradle file and make sure that it looks like this:
compilesdkversion is set to
framework, class library, and self-developed code.
This problem can be solved by splitting a DEX file into multiple DEX files. Facebook introduced the Dalvik patch for Android apps. The Android Developers blog introduced how to solve this problem through the custom class loading process. However, these methods are complex and not elegant.
With the release of the new MultiDex support library, Google officia
recommend the official documentation and this GitHub article to see a better understanding, less detours.Let's talk about the steps used:1. Modify Gradle, import ' com.android.support:multidex:1.0.0 ', open multidexenabled;Android {compilesdkversion +buildtoolsversion"21.1.0"defaultconfig {... minsdkversion -targetsdkversion + ... //enabling Multidex support.Multidexenabledtrue } ...} d
version name. You don't need to change anything at the beginning, but each time you release a new application, you must change these values, so they are very important. Version Number-Android and the market use it to distinguish different version names-user-visible version strings, Android OS and the market will show that it needs to change each new release
Minimum and target SDK. Qt Creator uses
An entry-level tutorial written by Action bar in Android Application Development. It is used for android application development.
In addition to Fragment, which we have focused on since Android 3.0, Action Bar is also an important part. Action Bar is mainly used to replace the traditional title Bar, for an Android tabl
(). Getstringarray (R.array.planets_array); Set the adapter for the "List view Mdrawerlist.setadapter" New arrayadapter
The more tangled is the use of level 11 of an API, so that minsdkversion have limitations, not too low.
Photo Resource The Android website sample is available for download.
After the program is run the effect is as follows:Before opening the drawer:
After the drawer opens:
Code
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.