User Profile

Collapse

Profile Sidebar

Collapse
green
green
Last Activity: Oct 23 '07, 12:57 PM
Joined: Oct 21 '07
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • green
    replied to SocketChannel problem
    in Java
    No, It does not work

    I have a big problem withe the ordinary socket...
    See more | Go to post

    Leave a comment:


  • green
    started a topic SocketChannel problem
    in Java

    SocketChannel problem

    dear all ,
    I'm trying to write a socket program . using the SocketChannel.. .
    but I don't receive any thing from the server. why ???????

    this my code


    Code:
            address = new InetSocketAddress("***.***.**.**",**** );
            channel = SocketChannel.open(address);              
            byte[] b = getAuthenticationLoginString("***","********");
    ...
    See more | Go to post

  • green
    replied to socket
    in Java
    The answer for your question is (yes)., server sends a bunch of bytes

    is socketchannel solve this problem ??
    socketchannel is non-blocking..

    waiting




    can I write to u directly ?? to ur eamil...
    See more | Go to post

    Leave a comment:


  • green
    replied to socket
    in Java
    dear Jos,
    thanks for reply..
    I'm in a big problem , that I can't solve it
    my IT director ask me to build an application to get data from a server.
    so I make a socket connection with this server.
    I send first the authentication to the server, so server send ALLOW message.
    then I start to send request and it response with a response message.
    the PROBLEM is that I can't get all the response message....
    See more | Go to post

    Leave a comment:


  • green
    started a topic socket
    in Java

    socket

    I have an application that send requests to a server and then server respond.

    request ... response
    request ... response
    ... ...


    so how can I manage this application?
    can I used the socketChannel or socket ??????????????? ???

    blocking sockets or non-blocking sockets ??????????????? ?


    please reply
    See more | Go to post

  • green
    replied to socket problem,,,,, plz help
    in Java
    many thanks for u and for ur valuable time
    ---------------------------------------------------------------
    so I tried to get all the data by looping with the InputStream, but I get another problem


    [code=java]
    os.write(getAut henticationRedG reenInfoString( ));
    os.flush();
    Thread.sleep(30 00); // must sleep a while to get the server response
    DataInputStream is = new DataInputStream (mySocket.getIn putStream());...
    See more | Go to post
    Last edited by JosAH; Oct 21 '07, 02:02 PM. Reason: change the tag; Java code is not a poem ;-)

    Leave a comment:


  • green
    started a topic socket problem,,,,, plz help
    in Java

    socket problem,,,,, plz help

    my problem is

    I have socket between server and a client
    the client sending data to the server, so the server respond to the client with the response
    this my code for receive the response data
    ----------------------------------------------------------
    os.write(getAut henticationRedG reenInfoString( ));
    os.flush();
    Thread.sleep(30 00);
    DataInputStream is = new DataInputStream (mySocket.getIn putStream());...
    See more | Go to post
No activity results to display
Show More
Working...