簡體   English   中英

如何解決呢? -“'C:\\ Users \\ dmgop \\ AppData \\ Local \\ Android \\ Sdk \\ build-tools \\ 27.0.3 \\ aapt2.exe上缺少aapt2”

[英]How to solve this? - “aapt2 is missing on 'C:\Users\dmgop\AppData\Local\Android\Sdk\build-tools\27.0.3\aapt2.exe' ”

This is a basic program on android to display 2 texviews and 1 button.

我無法在手機上運行以下代碼。 以下已在android studio中完成。

This is my code-
    <LinearLayout
        xmlns:android="http://schemas.android.com/apk/res/android"
        xmlns:app="http://schemas.android.com/apk/res-auto"
        xmlns:tools="http://schemas.android.com/tools"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:orientation="vertical"
        tools:context=".MainActivity">
    <TextView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="QUANTITY"
            />
            <TextView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="0"
                android:textStyle="bold"
             />
        <Button
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="ORDER"
            />

[ 在此處輸入圖片說明

您似乎已損壞了構建工具27.0.3。 刪除目錄C:\\Users\\dmgop\\AppData\\Local\\Android\\Sdk\\build-tools\\27.0.3\\ ,轉到Android Studio中的SDK Manager,然后重新下載構建工具27.0.3。 這應該為您解決此問題。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM