오류 메시지를 표시해야합니다. 카운터를 선언했습니다. 카운터가 3 일 때마다 다른 오류 메시지가 표시됩니다. 아래 코드를 작성했습니다. 선언에 error: <identifier> expected
을 반환합니다.한도 초과 후 다른 오류 메시지가 표시됩니까?
//declaration
private static attempts = 0;
//operation
switch (xmlRpcFault.getFaultCode()) {
case 403:
attempts++;
if(attempts = 3)
{
mErrorMsgId = R.string.username_or_password_incorrect;
//reinitialize counter
attempts = 0;
}
else
mErrorMsgId = R.string.username_or_password_incorrectfull;
break;
이것은 컴파일되지 않습니다. – njzk2
@ njzk2 예, OP가 그 이유를 묻고 있습니다. –
좋은 IDE라면 누구에게 말해 줄 수 있습니다. – njzk2