Summary of errors encountered during android development and SolutionsIf any errors or solutions have been encountered during the Development summarized by the novice, please correct them. If you have any better solutions, please kindly advise.1. android. view. WindowManager $ BadTokenException error caused by dialog.
Android Force Close causes and solutions: androidforceI. Reasons:
Forceclose indicates that the current application has a conflict.
NullPointExection (NULL pointer), IndexOutOfBoundsException (subscript out-of-bounds), even errors in the sequence of Android API usage may cause (for example, a series of uncaptured exceptions such as findViewById () operations befo
Conclusion
only the fifth step, and no sixth step, throws an exception in the Cameraconfigurationutils 283 row of the Zxing class library
IllegalStateException ("Parameters contained no preview size!");
If the sixth step is taken without the fifth step, the barcode will not be recognized properly.
Well, after the above six steps, Zxing Barcode scanner has been able to scan the normal vertical screen, the rest of the work is to streamline the code, I wish everyone s
Port 5037 *Could not read OK from ADB Server, error = 109* Failed to start daemon *Error:cannot Connect to DaemonE:\ANDROID\ANDROID-SDK-WINDOWS\PLATFORM-TOOLS>ADB devices* Daemon not running. Starting it now on Port 5037 ** Daemon started successfully *List of devices attached2cbe000400000001 DeviceAndroid ADB shell:unknown Host ServiceAfter we enter the ADB shell in the Windows DOS window, the following e
the events already mentioned).If you insert a delay between events, use the parameter:--throttle 5000 Here The 5000 is the millisecond unit. With this option, you can reduce the execution speed of the monkey, and if you do not specify this option, monkey will not be delayed and events will be generated as soon as possible.-S Each-V of the-V command line increases the level of feedback information.As for the other parameters, Baidu a bit, for the time being first written here.Six, in the Monkey
Starting with Android Studio update to 2.0 stable version, debugging when there is no problem, in the packaging when the "App_name" is not the translated in En, zh_cn ...., the problem is that localization is incomplete meaning.In the final analysis, this is the time to pack the problem, so the hint is also clear, is to change the configuration. Here's how to fix it:Open the project directory under the Build.gradle file (this is the Gradle configurati
Android mobile phones and computers transmit data based on WiFi. Technically speaking, there are two main solutions:
One is implemented through the FTP protocol, and the Android mobile phone is used as the FTP server during data transmission;
One is implemented through HTTP. Android phones are used as HTTP servers duri
: * Packagemanager may fail to update the shared library. * * Native Library directory in an updated package is a symbolic link * to a directory In/data/app-lib/ "The dangers of loading a local library on Android" This article mentions the same problem that the author encounters and is based on an expedient solution given by Chromium: encapsulating the System.loadlibrary interface as a ReLi
When you use Android Studio to develop Android apps and install Android apps on your phone, there's a hint of installation failure: Install_failed_uid_changed.Surf the internet to find a lot of information:1. Say that there is no uninstall clean, you need to use the ADB shell command to delete the remaining folder of the app.1 cd/data/data2 rm-r App package nameh
in the Build.gradle file inside each model compileSdkVersion 21 .4.3
Error: (44, 30) errors: The diamond operator is not supported in-source 1.6 (use-source 7 or later to enable the diamond operator)
The reason for the error is List that Java introduced the diamond operator in 1.7 in the code, and there are two workarounds. One is to change the version of the compiled Java SDK, instead of changing the error code toList4.4
Error: (PNS) No resource Identifier found for att
First of all, you may have accidentally seen this article ... Yes, I'm completely on the first contact with Android development ... So the problems encountered are very simple ... (Most of the solutions are selected from StackOverflow)OneForget, after the new project, did not move any code, but various save. OK, because the SDK download is not complete, such as the default new project is
events, and how to specify different proportions of the events already mentioned).If you insert a delay between events, use the parameter:--throttle 5000 Here The 5000 is the millisecond unit. With this option, you can reduce the execution speed of the monkey, and if you do not specify this option, monkey will not be delayed and events will be generated as soon as possible. -S Each-V of the-V command line increases the level of feedback information.As for the other parameters, Baidu a bit, for
Three solutions for updating the UI using the Handler mechanism in Android
Recently, I want to write down my Handler experience in the course of learning Android for you to view it later and share it with you.
Handler has to be connected to threads in Android or multiple threads in Java. This article will only use the
(Bundle savedinstancestate) { super.oncreate (savedinstancestate); Setcontentview (r.layout.activity_main); Text = (TextView) Findviewbyid (r.id.id_text); New Thread () { @Override public void Run () { //... Your business logic; message message = new Message ();//Send a message that is used to distinguish who sent the message in handlemessage; message.what = 1; Handler.sendmessage (mess
interconnection, no advantage.7, when you say that voice control to achieve the recognition rate of networking, it is the same feeling.8, you want to explain why broadcast SD/USB when the navigation voice broadcast, is four speakers are making sound, not only the first two speakers.9, why Android boot time to about 25 seconds, and wince as long as 10 seconds?10, your UI is not flashy, no technology sense, how not like a certain so that there is three
. If the FQ software is turned on, the speed is slow. My internet speed is 10M Campus network, with the FQ software download for 200kb/s. Later found a good article, introduced a very good way. That is to change the contents of the Hosts file under the C:\WINDOWS\system32\drivers\etc directory to the following content.127.0. 0.1 Localhost#google Home 203.208. 46.146 www.google.com# This line is for the convenience of opening the Android development we
Try this, can solve the difficulties of domestic access to Google Server launch Android SDK Manager, open the main interface, select "tools", "options...", pop up "Android SDKManager-settings "window, in the" Android SDK manager-settings "window, in the"http proxy server"and"http proxy port"input BoxFill in mirrors.neusoft.edu.cn and 80, and select "forcehttps://
Try this to solve the difficulties of accessing Google servers in ChinaLaunch Android SDK Manager, open the main interface, select "tools", "options...", pop up the "Android SDK manager-settings" window;In the Android SDK manager-settings window, fill in port"and 80 in the"http proxy server"and"http proxy mirrors.neusoft.edu.cn input boxes, and select "force c2>h
critical life-cycle methods, such as OnCreate () and Onresume (). (You can do something by re-opening the sub-thread and then using Handler+message to do things like updating the UI in the main thread, etc.)2, the application should avoid doing time-consuming operation or calculation in Broadcastreceiver. Instead of doing these tasks in a sub-thread (because of the short life cycle of broadcastreceiver), the application should start a Service if responding to intent broadcasts requires a time-c
. Proxy returns "http/1.1-Bad Request" solution 1. Open settings 2. Select the first step in the diagram, and then the second step. and set the Gradle directory 3. After setting up the application, and click OK. 4. Refresh Gradle 5. Run, Error resolved If there is no gradle, you can go to: http://services.gradle.org/distributions to download, unzip, and then you can follow this method to choosehttp://m.blog.csdn.net/article/details?id=51046313Android N requires the IDE to being running w
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.