at android.app.Instrumentation.checkStartActivityResult(Instrumentation.java)
at android.app.Instrumentation.execStartActivity(Instrumentation.java)
at android.app.ContextImpl.startActivity(ContextImpl.java)
at android.app.ContextImpl.startActivity(ContextImpl.java)
at android.content.ContextWrapper.startActivity(ContextWrapper.java)
at com.yinzhan.conferences.adapter.ConferencesStayAdapter$1.onClick(ConferencesStayAdapter.java:83)
at android.view.View.performClick(View.java)
at android.view.View$PerformClick.run(View.java)
at android.os.Handler.handleCallback(Handler.java)
at android.os.Handler.dispatchMessage(Handler.java)
at android.os.Looper.loop(Looper.java)
at android.app.ActivityThread.main(ActivityThread.java)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:525)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java)
at dalvik.system.NativeStart.main(Native Method)
其中的dat= http://www.jinmahotels.com里面有空格
解决方法是在填数据的时候多了空格
.trim() 就可以了
.trim() 是String 类中的方法
/**
* Copies this string removing white space characters from the beginning and
* end of the string.
*
* @return a new string with characters <code><= \\u0020</code> removed from
* the beginning and the end.
*/
public String trim() {
int start = offset, last = offset + count - 1;
int end = last;
while ((start <= end) && (value[start] <= ' ')) {
start++;
}
while ((end >= start) && (value[end] <= ' ')) {
end--;
}
if (start == offset && end == last) {
return this;
}
return new String(start, end - start + 1, value);
}