|
This example shows how to send a WAP Push using the Clickatell
network:
Dim sURL As
String
Dim objXMLHTTP As New MSXML2.XMLHTTP
Dim objWAPPush As ServiceIndicationMessage
Dim objPDU As WAPPDU
Set objWAPPush = New ServiceIndicationMessage
objWAPPush.URI = "http://www.yoururl.com"
objWAPPush.MessageText = "Your message"
objWAPPush.GeneratePDU
For Each objPDU In objWAPPush.PDUs
sURL = "http://api.clickatell.com/http/sendmsg?"
sURL = sURL & "api_id=APIID&user=uid&password=pwd&"
sURL = sURL & "to=&"
sURL = sURL & "udh=" & objPDU.UserDataHeader & "&"
sURL = sURL & "text=" & objPDU.MessageData
objXMLHTTP."POST", sURL, False
objXMLHTTP.send
If Left(objXMLHTTP.responseText, 2) = "ID" Then
MsgBox "WAP Push Sent"
End If
Next
|