android - aapt error: Archive is toast

When running certain builds on Jenkins, I have been getting this error and I can't seem to figure out how to prevent this from happening. So far my only work around for this is deleting the entire Jenkins workspace. Any suggestions on a cleaner solution to this problem? And what does this error mean? E/zip (57580): error during crunch - archive is toast ERROR: failed opening/creating 'debug.apk' as Zip file:mobile:generateAPKs FAILED Process 'command '/Users/admin/Library/Android/sdk/build-tools/27.0.1/aapt'' finished with non-...Read more

android - Xamarin.Forms ViewRenderer audio doesnt stop on homepage/backbutton

I am new so excuse me if I dont ask a question right or post enough information. I am new to creating mobile applications and i am using Xamarin.Forms to create a custom view. with this view I am using an Android ViewRenderer to play audio/video with built in android MediaPlayer/VideoView. pretty much the exact same thing as the android renderer posted and accepted as the answer for Renderer I copied and is workingMy issue is when the video starts and you click the homepage/back button the audio continues playing for a few seconds and then st...Read more

android - 'Resource.Designer.cs' doesn't open with any 'designer'

I'm using Visual Studio 2017 with the latest update.I created a new Xamarin Forms solution (.net standard) and when I click on Resource.Designer.cs or when I try to "open with" with many options - I don't get any designer.Since the text in the file says // <auto-generated>// This code was generated by a tool.// Runtime Version:4.0.30319.42000//// Changes to this file may cause incorrect behavior and will be lost if// the code is regenerated.// </auto-generated>Something must be missing.How do I get the designer worki...Read more

Web colors in an Android color xml resource file

What do all of the X11/w3c color codes look like in the format of an Android XML resource file? I know this looks a tad ridiculous as a question, but given the votes apparently it's useful and since it clearly does not require an off-site resource I'm reformatting it to keep it around. --Editor....Read more

xml - What's "tools:context" in Android layout files?

Starting with a recent new version of ADT, I've noticed this new attribute on the layout XML files, for example:<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" tools:context=".MainActivity" />What is "tools:context" used for?How does it even know the exact path to the activity that is written there? Does it look at the package of the app, inside the man...Read more

android - Change the default color of main activity when it starts, The starting and opening default color

When user opens any application by clicking on app icon, the app starts with mainactivity.java. and its xml layout is shown to user.I am making a splash screen with simple background color and text. But what my problem is, when it starts it shows a default layout color for a very little fraction of time and then it draws my given color. I do not want default color to be there even for that small fraction of time. <?xml version="1.0" encoding="utf-8"?><android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com...Read more

android - How to get Background Shape color of buttons?

I have 9 custom round buttons each when clicked opens the color picker and a save button at bottom view retrieves all the data .My problem is i am not able to retrieve the color correctly.and also the code can retrieve the data above 24 version .that is also useless.Sample code This code is invoked everytime the button is click .it gets the color value from color picker.GradientDrawable c1, c2; Button mcbt_1,mcbt_2; // this function gets call everytime button is clicked ,it sets the color to the background and maintain the shap...Read more

How do save an Android Activity state using save instance state?

I've been working on the Android SDK platform, and it is a little unclear how to save an application's state. So given this minor re-tooling of the 'Hello, Android' example:package com.android.hello;import android.app.Activity;import android.os.Bundle;import android.widget.TextView;public class HelloAndroid extends Activity { private TextView mTextView = null; /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); mTextView = new TextView(this);...Read more

performance - Why is the Android emulator so slow? How can we speed up the Android emulator?

I have got a 2.67  GHz Celeron processor, and 1.21  GB of RAM on a x86 Windows XP Professional machine. My understanding is that the Android Emulator should start fairly quickly on such a machine, but for me, it does not. I have followed all the instructions in setting up the IDE, SDKs, JDKs and such and have had some success in starting the emulator quickly, but that is very rare. How can I, if possible, fix this problem?Even if it starts and loads the home screen, it is very sluggish. I have tried the Eclipse IDE in version 3.5 (Gal...Read more