问题描述
在将Delphi从v10.2.2升级到v10.2.3之后,TBannerAd标语在尝试调用LoadAd方法时引发异常.
After upgrading Delphi from v10.2.2 to v10.2.3, the TBannerAd banner raised exception when trying to call the LoadAd method.
了解到东京10.2.3已更新Google Play服务及其库".(升级后, Google AdMob TBannerAd LoadAd例外到Delphi v10.2.3 ),我通过右键单击项目管理器"中的"Android库"节点,尝试了建议的将系统文件还原为默认值"的修复程序.
After understanding that "Tokyo 10.2.3 has updated Google Play Services and its libraries." (Google AdMob TBannerAd LoadAd exception after upgrading to Delphi v10.2.3), I tried the suggested fix of "Reverting System Files to Default" by right-clicking the Android Libraries node in the Project manager.
但是,这样做破坏了编译,并返回此错误:
However, doing so broke compilation, returning this error:
[Exec Error] The command "PATH {my entire path} & "C:\Users\MyUser\Documents\Embarcadero\Studio\19.0\PlatformSDKs\android-sdk-windows\build-tools\27.0.2\dx.bat" --dex --output="Z:\Tic\Android\Debug\classes.dex" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\android-support-v4.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\cloud-messaging.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\fmx.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\google-analytics-v2.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\google-play-billing.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\google-play-licensing.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\google-play-services-ads-7.0.0.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\google-play-services-analytics-7.0.0.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\google-play-services-base-7.0.0.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\google-play-services-identity-7.0.0.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\google-play-services-maps-7.0.0.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\google-play-services-panorama-7.0.0.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\google-play-services-plus-7.0.0.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\google-play-services-wallet-7.0.0.dex.jar" "c:\program files (x86)\embarcadero\studio\19.0\lib\Android\Debug\google-play-services.dex.jar" " exited with code 2.
我手动输入了命令,这是完整的错误消息:
I manually entered the command and this is the full error message:
项目管理器下列出的Android SDK为v24.3.3 32位.
The Android SDK listed under the project manager is v24.3.3 32bit.
我想念Android方面的更新吗?
Did I miss updating something on the Android side?
推荐答案
我在解决该问题的原始线程上得到了答案,看来使用将系统文件还原为默认值"选项仍然保留了旧的"google-play"功能-services.dex.jar"服务.
I got an answer on the original thread that resolves this, it seems that using the "Reverting System Files to Default" option still left the old "google-play-services.dex.jar" service.
要解决此问题,我右键单击该条目并选择禁用",关闭Delphi,在文本编辑器中打开项目的".dproj"文件,搜索"DisabledSysJars"并删除有问题的条目.
To fix the issue, I right-clicked the entry and selected "Disable", closed Delp opened my project's ".dproj" file in a text editor, searched for "DisabledSysJars" and removed the problematic entry.
这篇关于Android库“将系统文件还原为默认"在Delphi v10.2.2到v10.2.3升级失败之后的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!