@SuppressWarnings("unused")
	protected void withdrawActionFromPublic() {
		// Action type
		Object typeValueItem = actionsListJlst.getSelectedValue();
		String typeValue = null;
		if (typeValueItem != null ) {
			typeValue = typeValueItem.toString();
		}
		// Title value
		Object titleObject = titleJlst.getSelectedValue();
		int selectedIndex = titleJlst.getSelectedIndex();
		String titleValue = null;
		if (titleObject != null) {
			titleValue = titleObject.toString();
		}
		boolean withdrawFlag = false;
		switch (typeValue) {
		case CASECLAIM:
			if (titleValue != null) {
				for (int i = 0; i < claimResultList.size(); i++) {
					if (claimResultList.get(i).getTitle().equals(titleValue)) {
						currentClaim = claimResultList.get(i);
						currentClaim.setDialogType(ACTIONPRIVATE);
						currentClaim.setTeam(teamType);
						if (action.withdraw(fileName, currentClaim)) {
							JOptionPane.showMessageDialog(this, "You have successfully withdraw the claim", "Success", JOptionPane.OK_OPTION);
							withdrawFlag = true;
							break;
						} else {
							JOptionPane.showMessageDialog(this, "You have failed to withdraw the claim", "Failed", JOptionPane.WARNING_MESSAGE);
						}
					}
				}
			}
			break;
		case CASESUBCLAIM:
			if (titleValue != null) {
				for (int i = 0; i < subclaimResultList.size(); i++) {
					if (subclaimResultList.get(i).getTitle().equals(titleValue)) {
						currentClaim = subclaimResultList.get(i);
						currentClaim.setDialogType(ACTIONPRIVATE);
						currentClaim.setTeam(teamType);
						if (action.withdraw(fileName, currentClaim)) {
							JOptionPane.showMessageDialog(this, "You have successfully withdraw the sub claim", "Success", JOptionPane.OK_OPTION);
							withdrawFlag = true;
							break;
						} else {
							JOptionPane.showMessageDialog(this, "You have failed to withdraw the sub claim", "Failed", JOptionPane.WARNING_MESSAGE);
						}
					}
				}
			}
			break;
		case CASEEVIDENCE:
			if (titleValue != null) {
				for (int i = 0; i < evidenceResultList.size(); i++) {
					if (evidenceResultList.get(i).getTitle().equals(titleValue)) {
						evidenceCurrent = evidenceResultList.get(i);
						evidenceCurrent.setDialogType(ACTIONPRIVATE);
						evidenceCurrent.setTeam(teamType);
						if (action.withdraw(fileName, evidenceCurrent)) {
							JOptionPane.showMessageDialog(this, "You have successfully withdraw the evidence", "Success", JOptionPane.OK_OPTION);
							withdrawFlag = true;
							break;
						} else {
							JOptionPane.showMessageDialog(this, "You have failed to withdraw the evidence", "Failed", JOptionPane.WARNING_MESSAGE);
						}
					}
				}
			}
			break;
		case CASECOUNTERCLAIM:
			if (titleValue != null) { 
				System.out.println("withdraw counter claim");
				selfCounterClaimResultList = claim.getClaims(fileName, COUNTERCLAIM, teamType);
				for (int i = 0; i < selfCounterClaimResultList.size(); i++) {
					if (selfCounterClaimResultList.get(i).getTitle().equals(titleValue)) {
						currentClaim = selfCounterClaimResultList.get(i);
						currentClaim.setDialogType(ACTIONPRIVATE);
						currentClaim.setTeam(teamType);
						System.out.println("counter claim");
						if (action.withdraw(fileName, currentClaim)) {
							JOptionPane.showMessageDialog(this, "You have successfully withdraw the counter claim", "Success", JOptionPane.OK_OPTION);
							withdrawFlag = true;
							break;
						} else {
							JOptionPane.showMessageDialog(this, "You have failed to withdraw the counter claim", "Failed", JOptionPane.WARNING_MESSAGE);
						}
					}
				}
			}
			break;
		case CASECOUNTEREVIDENCE:
			if (titleValue != null) {
				for (int i = 0; i < selfCounterevidenceResultList.size(); i++) {
					if (selfCounterevidenceResultList.get(i).getTitle().equals(titleValue)) {
						evidenceCurrent = selfCounterevidenceResultList.get(i);
						evidenceCurrent.setDialogType(ACTIONPRIVATE);
						evidenceCurrent.setTeam(teamType);
						if (action.withdraw(fileName, evidenceCurrent)) {
							JOptionPane.showMessageDialog(this, "You have successfully withdraw the counterevidence", "Success", JOptionPane.OK_OPTION);
							withdrawFlag = true;
							break;
						} else {
							JOptionPane.showMessageDialog(this, "You have failed to withdraw the counterevidence", "Failed", JOptionPane.WARNING_MESSAGE);
						}
					}
				}
			}
			break;
		case CASEBIPOLARQUESTION:
			if (titleValue != null) {
				for (int i = 0; i < bipolarQuestionList.size(); i++) {
					if (bipolarQuestionList.get(i).getTitle().equals(titleValue)) {
						bipolarQuestionCurrent = bipolarQuestionList.get(i);
						bipolarQuestionCurrent.setDialogType(ACTIONPRIVATE);
						bipolarQuestionCurrent.setTeam(teamType);
						if (action.withdraw(fileName, bipolarQuestionCurrent)) {
							JOptionPane.showMessageDialog(this, "You have successfully withdraw the Bi-polar Questions", "Success", JOptionPane.OK_OPTION);
							withdrawFlag = true;
							break;
						} else {
							JOptionPane.showMessageDialog(this, "You have failed to withdraw the Bi-polar Questions", "Failed", JOptionPane.WARNING_MESSAGE);
						}
					}
				}
			}
			break;
		case CASERESPONSETOBIPOLAR:
			if (titleValue != null) { 
				for (int i = 0; i < bipolarQuestionList.size(); i++) {
					if (bipolarQuestionList.get(i).getTitle().equals(titleValue)) {
						bipolarQuestionCurrent = bipolarQuestionList.get(i);
						bipolarQuestionCurrent.setDialogType(ACTIONPRIVATE);
						bipolarQuestionCurrent.setTeam(teamType);
						if (action.withdraw(fileName, bipolarQuestionCurrent)) {
							JOptionPane.showMessageDialog(this, "You have successfully withdraw the Bi-polar Questions", "Success", JOptionPane.OK_OPTION);
							withdrawFlag = true;
						} else {
							JOptionPane.showMessageDialog(this, "You have failed to withdraw the Bi-polar Questions", "Failed", JOptionPane.WARNING_MESSAGE);
						}
					}
				}
			}
			break;
		case CASECHALLENGE:
			if (titleValue != null) { 
				for (int i = 0; i < challengeList.size(); i++) {
					if (challengeList.get(i).getTitle().equals(titleValue)) {
						challengeCurrent = challengeList.get(i);
						challengeCurrent.setDialogType(ACTIONPRIVATE);
						challengeCurrent.setTeam(teamType);
						if (action.withdraw(fileName, challengeCurrent)) {
							JOptionPane.showMessageDialog(this, "You have successfully withdraw the Challenge", "Success", JOptionPane.OK_OPTION);
							withdrawFlag = true;
						} else {
							JOptionPane.showMessageDialog(this, "You have failed to withdraw the Challenge", "Failed", JOptionPane.WARNING_MESSAGE);
						}
					}
				}
			}
			break;
		}
		
		if (withdrawFlag) {
			this.dispose();
			DebateGUI debateGUI = new DebateGUI(userLogin, debateSelected);
			debateGUI.setLocation(50, 10);
			debateGUI.setVisible(true);
		}
				
		
	}