×

Discussion Board

Results 1 to 3 of 3
  1. #1
    Super Contributor
    Join Date
    Feb 2004
    Location
    Dallas
    Posts
    605

    Sending Commands

    I want to setup a network connection with a remote machine.

    Then that machine can accept commands and on the basis of those commands gives some response.

    I want to read that response also .

    1. Which all classes will i use?
    2. How will i send the command to remote machine.
    3. When the remote machine will give the resposne .. how will i receive it .

    How to go about it .I m very new to networking part in C++.

  2. #2
    Regular Contributor
    Join Date
    Mar 2004
    Location
    Novi Sad - Serbia
    Posts
    63

    Network connection

    Hi amitaggarwal,

    If you want to write your application for Symbian 7.0s than you can easily use HTTP connection to communicate with a remote machine running for example Tomcat or some other server.
    To be able to do that you should derive your own class from MHTTPTransactionCallback abstract class and you should implement these functions:
    Code:
    	virtual void MHFRunL(RHTTPTransaction aTransaction, const THTTPEvent& aEvent);
    	virtual TInt MHFRunError(TInt aError, RHTTPTransaction aTransaction, const THTTPEvent& aEvent);
    Other classes you must use are: RHTTPSession and RHTTPTransaction (there are other classes too).

    There is an example that comes with Series 60 SDK and it is located in: Examples\appprots\exampleclient directory so you can start with it.

    I hope this will help you.

  3. #3
    Super Contributor
    Join Date
    Feb 2004
    Location
    Dallas
    Posts
    605
    Thanks Sasa

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×