类的名称不显示为绿色,将鼠标悬停在它们上方显示“class或interface expected”。单击“运行并显示
”时,应用程序无法安装Error while executing: am start -n
"com.example.alber.piwas/com.example.alber.piwas.Login" -a
android.intent.action.MAIN -c android.intent.category.LAUNCHER
Starting: Intent { act=android.intent.action.MAIN cat=
[android.intent.category.LAUNCHER] cmp=com.example.alber.piwas/.Login }
Error type 3
Error: Activity class
{com.example.alber.piwas/com.example.alber.piwas.Login} does not exist.
Error while Launching activity
这是AndroidManifest中的代码。 Login,User和Signup3都是类。
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.alber.piwas">
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme">
<activity android:name="com.example.alber.piwas.Login">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".User">
<intent-filter>
<action android:name="com.example.alber.piwas.User" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<meta-data
android:name="preloaded_fonts"
android:resource="@array/preloaded_fonts" />
<activity android:name=".Signup3">
<intent-filter>
<action android:name="com.example.alber.piwas.Signup3" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
</application>
</manifest>