private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {  
    	boolean canInit = true;
    	if(jTextField1.getText().isEmpty()){
    			jTextField1.setToolTipText("This can not be Empty!!!");
    			jTextField1.setBackground(Color.red);
    			jLabel2.setText("UserName an not be Empty!!!");
    			canInit=false;
    		}
    	else 
    		jTextField1.setBackground(Color.green);
    	
    	 if(jCheckBox1.isSelected() && !(Client.validateIP(jTextField2.getText()))){
    		jTextField2.setToolTipText("This is not a vaild IP!!!");
    		jTextField2.setBackground(Color.red);
    		jLabel2.setText("NON-Valid IP!!!");
    		canInit=false;
    		
    	}
    	 else 
     		jTextField2.setBackground(Color.green);
    	 
    	if(canInit){
    		Client c = new Client(_logger);
    		c.setUsername(jTextField1.getText());
    		if(jCheckBox1.isSelected())
    			c.init(jTextField2.getText());
    		else{
    			jLabel2.setForeground(Color.green);
    			jLabel2.setText("Please Wait for someone to connect");
    			c.init();
    		}
    		gui.addChat(c);
    		setVisible(false);
        }
        
    }