我想询问Android是否接受JPEG图像而不是PNG,因为PNG具有更大的文件大小感谢JPEG,所以我想知道如何在layout.xml上使用JPEG作为背景图像.
我有webservice返回字符串值"1"或"-1",数字但在字符串中.
我在使用无法从字符串转换为org.ksoap2.serialization.SoapPrimitive的Asunc任务时出错
完整的AsuncTask类代码:
public class LoginAsync extends AsyncTask<Void, Void, String> {
Activity mActivity;
Context context;
ProgressDialog progressDialog;
public LoginAsync(Activity activity, ProgressDialog progressDialog,
Context context) {
super();
this.progressDialog = progressDialog;
this.mActivity = activity;
this.context = context;
}
@Override
protected String doInBackground(Void... voids) {
SoapPrimitive resultRequestSOAP = null;
try {
final String NAMESPACE = "http://ws.sams.com";
final String URL = "http://sams-app.com:8080/webService/services/LoginActvityWs?WSDL"; // usint
// //
// //
// //
// localhost
final String METHOD_NAME = "login";
final String SOAP_ACTION = "http://ws.sams.com/login";
SharedPreferences prefs …Run Code Online (Sandbox Code Playgroud)