在android上使用smsmsmanager.sendTextManager发送短信时出现问题
我正在从我的应用程序向使用5位数手机号码的服务器发送短信 在4.2.2操作系统上,它会在弹出窗口中询问我 已编辑 Q.如何处理取消/确定按钮 这应该可以在android上使用smsmsmanager.sendTextManager发送短信时出现问题,android,unity3d,android-4.2-jelly-bean,android-4.3-jelly-bean,Android,Unity3d,Android 4.2 Jelly Bean,Android 4.3 Jelly Bean,我正在从我的应用程序向使用5位数手机号码的服务器发送短信 在4.2.2操作系统上,它会在弹出窗口中询问我 已编辑 Q.如何处理取消/确定按钮 这应该可以 switch (getResultCode()) { // if cancel pressed then result code is 5 case 5: System.out.println("Message cancelled........"); break; // else
switch (getResultCode()) {
// if cancel pressed then result code is 5
case 5:
System.out.println("Message cancelled........");
break;
// else if send pressed then result code will be one of these below cases
case Activity.RESULT_OK:
break;
case SmsManager.RESULT_ERROR_GENERIC_FAILURE:
break;
case SmsManager.RESULT_ERROR_NO_SERVICE:
break;
case SmsManager.RESULT_ERROR_NULL_PDU:
break;
case SmsManager.RESULT_ERROR_RADIO_OFF:
break;
}
这是怎么回事??错误在哪里?我的问题是如何处理取消/确定按钮?