title: creating socket connection
body: <p>I need to create a socket connection between my machine and a server. Then I need to send some sms to server from my mechine using smpp protocol. Now I am not being able to create the socket connection. Can any body help me by giving some code to create the socket connection.</p>
  
  <p>My code is:</p>
  
  <pre><code> import java.io.IOException;
   import java.net.Socket;
  
   import com.logica.smpp.TCPIPConnection;
  
   public class SocketConnection {
  
      /**
       * @param args
       */
      public static void main(String[] args) {
          // TODO Auto-generated method stub
  
          SocketConnection tl= new SocketConnection();
          tl.connect();
  
      }
  
  
      public void connect()
      {
          TCPIPConnection tc = new TCPIPConnection("172.16.7.92", 9410);
          try {
              tc.accept();
              System.out.println("connected");
  
          } catch (IOException e) {
              // TODO Auto-generated catch block
              e.printStackTrace();
          }
      }
   }
  </code></pre>
  
  <p>this code is not working.</p>
  
  <p>Thanks,</p>
  
  <p>koushik</p>