@Override
	public void actionPerformed(ActionEvent e) {
		String action = e.getActionCommand();
		switch (action) {
		case "Start":
			boolean validInput = true;
			String userFisrtName = tfUserName.getText();
			String userLastName = tfUserLastName.getText();
			if (userFisrtName.equals("") || userLastName.equals("")) {
				validInput = false;
				dInvalidInput = new JDialog(this, "Error!");
				dInvalidInput.setSize(new Dimension(200, 100));
				dInvalidInput.setLocation(new Point(Global.SCREEN_WIDTH / 2,
						Global.SCREEN_HEIGHT / 2));
				JLabel lError = new JLabel("Please fill all the fields");
				JButton ok = new JButton("OK");
				ok.addActionListener(this);
				dInvalidInput.getContentPane().setLayout(new GridLayout(2, 1));
				dInvalidInput.getContentPane().add(lError);
				dInvalidInput.getContentPane().add(ok);
				dInvalidInput.setVisible(true);
				dInvalidInput.setFocusable(true);
				dInvalidInput.setResizable(false);
			}

			if (validInput == true) {
				String serverMessage = null;
				pw.println("REGUSER");
				try {
					serverMessage = br.readLine();
				} catch (IOException e1) {

					e1.printStackTrace();
				}
				if (serverMessage.equalsIgnoreCase("NAME"))
					pw.println(userFisrtName + " " + userLastName);
				else
					pw.println("REGUSER");

				TFQuestionFrame qFrame = new TFQuestionFrame(clientSocket);
				this.setVisible(false);
				qFrame.setVisible(true);
				this.dispose();
			}
			break;
		case "OK":
			dInvalidInput.dispose();
			break;
		default:
		}
	}