×

Discussion Board

Results 1 to 4 of 4
  1. #1
    Registered User
    Join Date
    Apr 2003
    Posts
    10

    Make SMS callback

    My MIDlet use WMA API.
    It send TextMessage,BinaryMessage to other divice

    But,
    Making wap push SMS, use TextMessage or BinaryMessage
    it's possible ??


    Always, result is normal SMS in receiver's Inbox

    SMS Sender : N3650
    SMS Receiver : N3650


    // send binarymessaging
    try {
    String url = "http://www.test.com/test/test.wml";
    byte data[] ;
    String bmark1="0B0504C34F00000003010101" ;

    String bm1 =
    "0605040B8423F072060A03AE81EAAF828DAED68701056A1661E5BDA9E59BBEE4B88BE8BDBD0045C60C03"
    + str2Hex(url)
    + "00080183000101" ;


    data = convertHexToBinary(bm1) ;

    String addr = "sms://" + gsm_number;
    MessageConnection conn = (MessageConnection)Connector.open(addr);

    BinaryMessage msg = (BinaryMessage)conn.newMessage(MessageConnection.BINARY_MESSAGE);
    msg.setPayloadData(data);
    conn.send(msg);

    }catch(Exception e)
    { System.out.println(e); }


    // other method
    private String str2Hex(String s) {...}
    private static byte[] convertHexToBinary(String hexData) throws Exception {...}

  2. #2
    Regular Contributor
    Join Date
    Apr 2003
    Posts
    184
    Did you manage to do it?

  3. #3
    Registered User
    Join Date
    Sep 2009
    Posts
    4

    Sms through bluetooth

    ===???????????????

  4. #4
    Regular Contributor
    Join Date
    Sep 2008
    Location
    Ahmedabad
    Posts
    254

    Re: Sms through bluetooth

    Hi,

    You need to send the SMS to port. I think you have not specified any port. J2ME application can listen for incoming messages that are directed onto any valid port.

    Hope that helps you out.
    Sunil
    Mobile Application Developer

Posting Permissions

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