public boolean addMessage(ChatMessage chatMessage){
		boolean returnValue = false;
		try {
			Socket socket = new Socket(SERVER_ADDRESS_CHAT, CHAT_PORT);
			
			socket.setSoTimeout(TIMEOUT);
			
			OutputStream outputStream = socket.getOutputStream();
			ObjectOutputStream objectOutputStream = new ObjectOutputStream(
					outputStream);
			objectOutputStream.writeObject("ADD_MESSAGE");
			chatMessage.setMessage(chatMessage.getMessage().replaceAll("[']", "''"));
			
			objectOutputStream.writeObject(chatMessage);
			objectOutputStream.flush();

			returnValue = (boolean)(new ObjectInputStream(socket.getInputStream())).readObject();
			socket.close();
			
			
		}catch (SocketException e){
			new ErrorFrame("Server unreachable!");
		} catch (SocketTimeoutException e){
			new ErrorFrame("Connection timed out");
		} catch (Exception e) {
			new ErrorFrame("An unknown Error occoured");
		}
		return returnValue;
	}