草庐IT

assetExists

全部标签

android - 检查是否存在 android Assets 文件夹 html 文件

我将html文件作为“file:///android_asset/WebApplication/index.html”传递。我如何在android中检查此文件是否存在。 最佳答案 您可以尝试打开流,如果失败则文件不存在,如果没有失败则文件应该在那里:/***Checkifanassetexists.Thiswillfailiftheassethasasize 关于android-检查是否存在androidAssets文件夹html文件,我们在StackOverflow上找到一个类似的问题