空格作为文件路径的一部分? [英] white space allowed as part of file path?
本文介绍了空格作为文件路径的一部分?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我的问题是有点相关的<一个href="http://stackoverflow.com/questions/5365780/android-asset-not-working-on-honeycomb">android_asset不工作的蜂窝?
My question is kinda related to android_asset not working on Honeycomb?
它是允许有一个HTML页面位于资产文件夹?
Is it allowed to have spaces in the file path name of an html page located in the assets folder?
有关恩:是以下法律
mWebView = (WebView) findViewById(R.id.webView1);
mWebView.loadUrl("file:///android_asset/Help File/helpfile.html");
有没有其他的解决办法不是重命名帮助文件目录中有没有空格在里面等?
Is there any other solution other than renaming the "Help File" directory to have no spaces in it?
TIA。
推荐答案
使用一个URI,这将解决这些问题。
Use a URI, which will address such issues.
mWebView.loadUrl(new URI("file:///android_asset/Help File/helpfile.html"))
这篇关于空格作为文件路径的一部分?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文