转自:https://blog.csdn.net/gbstyle/article/details/82926358 

错误1:

com.android.ddmlib.AdbCommandRejectedException: device unauthorized.
This adb server's $ADB_VENDOR_KEYS is not set
Try 'adb kill-server' if that seems wrong.
Otherwise check for a confirmation dialog on your device.
Error while Installing APK

 

解决方案:

手机-设置-应用程序-开发-usb调试打开再关闭一次

错误2:

 

关于FrameLayout的介绍是:FrameLayout内的子View会被绘制在一个栈中,最后添加的组件会被添加在最上面。按照这样的说法,应该是ImageView会覆盖在Button上面的。但是实际的效果却是这个样子的:

 

按钮显示在了FrameLayout的顶部。

原因分析:

按钮在Lollipop以及之后的版本,默认都有一个高度,这个也就是造成为什么在FrameLayout中绘制的时候会被绘制在最上层。

解决方法一:

设置Button的stateListAnimator属性

android:stateListAnimator="@null"

不过这样做的话,按钮的阴影效果也会不见

解决方法二:

设置其他View的elevation属性

<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@mipmap/ic_launcher"
android:elevation="2dp"

 

错误3:

转自https://blog.csdn.net/crheh/article/details/78358004

在studio界面的run下面有一个框

android 错误解决

在里面选app文件夹 
android 错误解决 
之后再运行就好了

 

相关文章:

  • 2021-09-27
  • 2021-11-29
  • 2021-11-02
  • 2021-12-02
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-07-19
猜你喜欢
  • 2021-11-18
  • 2021-05-24
  • 2021-09-03
  • 2021-11-22
  • 2021-10-31
  • 2022-12-23
  • 2021-10-26
相关资源
相似解决方案