1. Introduction
1.1. What is the ActiveXperts SMS and MMS Toolkit?
Adding SMS, MMS and Pager capabilities to an application is not a simple matter. It
requires specialized knowledge that might be outside an individual programmer's
expertise. Today, Windows developers rely upon the power, flexibility and
reliability of the SMS and MMS Toolkit by ActiveXperts Software.
SMS and MMS Toolkit is an ActiveX/COM component, and provides SMS, MMS and Pager messaging
functionality.
With this Toolkit, you can
send and
receive SMS messages via a:
- GSM modem
- GSM phone
- SMPP compliant SMSC provider
- HTTP compliant SMSC provider
- Hayes compatible modem
With this Toolkit, you can also
send MMS messages via an:
- MM1 provider
- MM4 provider
- MM7 provider
With this Toolkit, you can also
send pager messages via a:
- SNPP Provider (alpha-numeric paging)
SMS and MMS Toolkit can be used by any of the following operating systems:
- Windows 2008
- Windows Vista
- Windows 2003
- Windows 2000
- Windows XP
SMS and MMS Toolkit can be used by any of the following development languages:
- Visual Basic .NET - Windows .NET based application
- Visual C# .NET - Windows .NET based applications
- Visual Basic 5.x or higher - Windows based applications
- Visual C++ 5.x or higher - Windows based applications
- Deplhi 7.x or higher - Windows based applications
- ASP .NET - Web site based on Active Server Pages and the .NET Framework
- ASP 2.x - Web site based on Active Server Pages (server-side scripting)
- PHP - Embedded HTML scripting
- VBScript - Windows based scripts
- VBA - Visual Basic for Applications
- Java/Javascript - Java based scripts
- HTML - Client scripts within HTML pages
- ColdFusion - Server based web applications
- Any other development platform that supports ActiveX/COM components.
1.2. SMS and MMS Toolkit features
SMS features:
- Send alphanumeric text SMS messages
- Send multimedia SMS messages, including ringtones, pictures and logo's
- Send new voicemail/e-mail/fax/MMS indications
- Verify delivery of outgoing SMS messages
- Send WAP Push messages
- Send WAP Bookmarks
- Send vCards
- Receive SMS messages
- Receive SMS messages from different storage locations
- Support for Unicode, to support foreign languages like Chinese, Turkisch, etc.
- Support for multi-part messages, to allow messages longer than 160 characters
- Support for GSM modems and GSM phones to send and receive SMS messages
- Support for SMS/HTTP providers for medium/large message volumes
- Support for SMPP (Short Message Peer to Peer) providers for large message volumes
- Support TAP/XIO and UCP dial-in SMSC providers
- Support Windows 'Phone and Modem devices' and direct COM ports
- Support Multi-threading environments. The component is thread-safe, which means it can be used in a multi-threaded environment
- Troubleshooting facilities by tracing all modem commands and responses
- Samples included for various development platforms: MS Visual Basic, MS Visual Basic .NET, MS Visual C++, MS Visual C# .NET, ASP, ASP .NET and more
MMS features:
- Supported image message types: JPG, GIF, PNG, BMP, WBMP, TIF
- Supported sound message types: WAV, MP3, MIDI, AC3
- Supported video message types: GP3, AVI, MPG, MP4
- Other Supported message types: VCARD, VCALENDAR, JAR and more
- Support for MM1 (MMS over WAP). Requires a GPRS modem and a subscription to an MMSC
- Support for MM4 (MMS over SMTP). Requires SMTP connectivity to an MMSC through the internet/VPN
- Support for MM7 (MMS over HTML/SOAP). Requires connectivity to an MMSC through the internet/VPN.
Pager features:
- Send alpha-numeric Pager messages through SNPP
Generic:
- Support for multi-threading environments. The component is thread-safe, which means it can be used in a multi-threaded environment
- Troubleshooting facilities by tracing all modem/TAPI commands and responses
- Samples included for various development platforms: MS Visual Basic, MS Visual Basic .NET, MS Visual C++, MS Visual C# .NET, ASP, ASP .NET and more
1.3. SMS and MMS Toolkit Architecture
SMS and MMS Toolkit is built on top of the Microsoft serial device drivers
and TAPI drivers. It does NOT replace any Windows drivers during installation;
it neither adds any files or components to the Windows or Windows System directory.
The core of SMS and MMS Toolkit consists of one file:
-
AXmsCtrl.dll - the SMS and MMS Toolkit ActiveX object
The component encapsulates the following SMS objects:
- SmsConstants - This object is a collection of read-only SMS flags (so called constants) that can be used for various purposes
- SmsMessage - This object encapsulates all properties of an SMS message
- SmsProtocolGsm - Send and receive SMS messages using a GSM modem (like Falcom SAMBA 75 Quad Band GSM/GPRS USB Modem) or GSM phone (like Nokia 6310i)
- SmsProtocolHttp - Send medium/high volumes SMS messages. Use the ActiveXperts Demo SMS/HTTP gateway for testing, or sign-up with a commercial SMS/HTTP provider
- SmsProtocolSmpp - Send and Receive corporate and high volumes SMS messages. Use the ActiveXperts Demo SMPP server for testing, or sign-up with a commercial SMPP SMSC provider
- SmsProtocolDialup - Send SMS messages through an SMSC dial-up provider. This requires a standard Hayes compatible modem and a dial-in number of an SMSC provider
- SmsData objects - Format messages as WapPush, WapBookmark, Ringtone, Picture or MMS notification
The component encapsulates the following Pager objects:
- PagerProtocolSnpp - Send alpha-numeric pager messages. This requires an internet connection to an SNPP provider
The component encapsulates the following MMS objects:
SMS and MMS Toolkit can be distributed easily to many PC's. Once you have
purchased the licenses, you copy the AXmsCtrl.dll to the PCs and register the
DLL on that PC.
Click here for more information about the installation.
2. System requirements
2.1. ASP .NET, VB .NET, VC# .NET, ASP, VB, Visual C++ and more
The SMS and MMS Toolkit can be used by any of the following programming languages:
- Visual Basic .NET
- Visual C# .NET
- Visual Basic 5.x or higher
- Visual C++ 5.x or higher
- Delphi 6.x or higher
- ASP .NET
- ASP 2.x
- PHP
- ColdFusion
- VBScript
- Java/Javascript
- HTML
- Any other development platform that supports ActiveX/COM components.
2.2. .NET Framework
To use SMS and MMS Toolkit in an ASP .NET, Visual Basic .NET or Visual C#.
NET environment, the .NET Framework must be installed on the system. The .NET
Framework is part of Windows Server 2008, Windows Server 2003 and Windows XP SP1. On Windows 2000 and Windows XP (no SP), it's
available as a separate installation. Please visit the
Technology Information for the .NET Framework page to download the .NET
Framework.
2.3. Internet Information Server
Internet Information Server (IIS) Setup installs the Visual Basic Script and
Java Script engines.
To run server-side ASP pages, IIS 6.x or higher must be installed. IIS is
part of the Windows XP Professional and Windows 2008/Vista/2003/2000/ Operating Systems. IIS is NOT supported on Windows XP Home.
2.4. Internet Explorer 6.x or higher
The Internet Explorer 6.x Setup (or higher) installs the Visual Basic Script
and Java Script engines.
You can use the SMS and MMS Toolkit component from client HTML browser using Javascript.
2.5. Windows Scripting Host
SMS and MMS Toolkit can be used in VBScript scripts. VBScripts can be used by
passing the script-file as a parameter to the scripting host ( either 'cscript'
or 'wscript').
WSH relies on the Visual Basic Script and Java Script engines provided with
Internet Explorer 4.x or later. WSH is also installed as part of Windows 98,
Windows 2000/2003, Windows XP and Internet Information Services 4.0 or higher. A separate setup program
is provided for Windows 95.
2.6. Visual Basic
SMS and MMS Toolkit can be used in Visual Basic 5.x or higher.
2.7. Visual C++
SMS and MMS Toolkit can be used in Visual C++ 5.x or higher.
2.8. Delphi
SMS and MMS Toolkit can be used in Borland Delphi 6.x or higher.
4. SMS Messaging with SMS and MMS Toolkit
4.1. Introduction
With ActiveXperts SMS and MMS Toolkit, you can send and receive SMS messages via a GSM/GPRS modem, GSM/GPRS phone, SMS/HTTP provider,
SMPP provider or Hayes compatible modem. You can send/receive not only plain text messages, but also multi-part messages, Unicode SMS messages and
SMS data messages including WAP Push, WAP Bookmark, ringtones and picture messages.
The following code snippets (VBScript) illustrate how to use various SMS and MMS Toolkit objects for sending/receiving SMS messages.
Send a text SMS message via GSM/GPRS Modem
Set objSmsMessage = CreateObject( "ActiveXperts.SmsMessage" ) ' Create SmsMessage instance
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" ) ' Create SmsProtocolGsm instance
objSmsMessage.Recipient = "+31624896641" ' Set recipient's mobile number
objSmsMessage.Data = "Hello, world!" ' Set SMS message text
objGsmProtocol.Device = "MultiTech GSM MultiModem" ' Use MultiTech's Windows Telephony device
objGsmProtocol.EnterPin( "1234" ) ' SIM card's PIN code
objGsmProtocol.Send( objSmsMessage ) ' Send the SMS message now
WScript.Echo "Result: " & objGsmProtocol.LastError
Send a text SMS message via HTTP
Set objSmsMessage = CreateObject( "ActiveXperts.SmsMessage" ) ' Create SmsMessage instance
Set objHttpProtocol = CreateObject( "ActiveXperts.SmsProtocolHttp" ) ' Create SmsProtocolHttp instance
Set objSmsConstants = CreateObject( "ActiveXperts.SmsConstants" ) ' Create SmsConstants instance
objSmsMessage.Recipient = "+31624896641" ' Set recipient's mobile number
objSmsMessage.Sender = "+31638740160" ' Set sender
objSmsMessage.Data = "Hello, world!" ' Set SMS message text
' Provider Settings
objHttpProtocol.ProviderHost = "post.activexperts-labs.com" ' Set host
objHttpProtocol.ProviderPort = 8080 ' Set port (default port:80)
' Provider Response templates
objHttpProtocol.ProviderErrorResponse = "ERR" ' Response should NOT contain 'ERR'
objHttpProtocol.ProviderSuccessResponse = "id" ' Response should contain 'id'
' URL Template to submit plain text SMS messages
objHttpProtocol.URLText = "/sendsms/default.asp?username=AX008&password=812056&text=%MESSAGEDATA%&to=" & _
"%MESSAGERECIPIENT%&from=%MESSAGESENDER%"
objHttpProtocol.Send( objSmsMessage ) ' Send the message
WScript.Echo "Send, result:" & objHttpProtocol.LastError ' Display the result
WScript.Echo "Provider response:" & objHttpProtocol.ProviderResponse ' Display provider response
Send a text SMS message via SMPP
Set objSmsMessage = CreateObject( "ActiveXperts.SmsMessage" ) ' Create SmsMessage instance
Set objSmppProtocol = CreateObject( "ActiveXperts.SmsProtocolSmpp" ) ' Create SmsProtocolSmpp instance
objSmppProtocol.Server = "smpp.activexperts-labs.com" ' Set SMPP server (hostname or IP address)
objSmppProtocol.ServerPort = 2775 ' Set TCP/IP port of the SMPP server
objSmppProtocol.SystemID = "AX005" ' Set SMPP server login
objSmppProtocol.SystemPassword = "812056" ' Set SMPP server password
objSmppProtocol.Connect
If objSmppProtocol.IsConnected = True Then
objSmsMessage.Recipient= "+31647134225" ' Set recipient's mobile number
objSmsMessage.Data = "Hello World via SMPP" ' Set SMS message text
objSmppProtocol.Send( objSmsMessage ) ' Send the message
objSmppProtocol.Disconnect ' Disconnect
End If
WScript.Echo "Result: " & objSmppProtocol.LastError
Send a text SMS message via Dial-up provider
Set objSmsMessage = CreateObject( "ActiveXperts.SmsMessage" ) ' Create SmsMessage instance
Set objDialupProtocol = CreateObject( "ActiveXperts.SmsProtocolDialup" )' Create SmsProtocolDialup instance
Set objSmsConstants = CreateObject( "ActiveXperts.SmsConstants" ) ' Create SmsConstants instance
objSmsMessage.Recipient = "0624896641" ' Set recipient's mobile number
objSmsMessage.Sender = "0638740160" ' Set message sender
objSmsMessage.Data = "Hello, world!" ' Set SMS message text
objDialupProtocol.Device = "Standard 1200 bps Modem"
objDialupProtocol.DeviceSpeed = 1200 ' Provider-dependent; 0 for default (TAP 1200, UCP 2400)
objDialupProtocol.DeviceSettings = objSmsConstants.asDEVICESETTINGS_8N1 ' Provider-dependent; here we use 8 data bits,
' no parity, 1 stop-bit
objDialupProtocol.ProviderDialString = "+31653141414" ' Provider's dial-in number
objDialupProtocol.ProviderType = objSmsConstants.asPROVIDERTYPE_UCP ' UCP or TAP
objDialupProtocol.Send ( objSmsMessage )
WScript.Echo "Result: " & objDialupProtocol.LastError
Receive a text SMS message through GSM/GPRS Modem
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" ) ' Create SmsProtocolGsm instance
Set objSmsConstants = CreateObject( "ActiveXperts.SmsConstants" ) ' Create SmsConstants instance
objGsmProtocol.Device = "MultiTech GSM MultiModem"
objGsmProtocol.EnterPin ( "1234" ) ' SIM card's PIN code
objGsmProtocol.MessageStorage = objSmsConstants.asSTORAGE_ALL ' Set memory to all available storage locations
objGsmProtocol.Receive() ' Receive all messages from all memory locations
If( objGsmProtocol.LastError <> 0 ) Then
WScript.Echo "Failed to receive, error: " & objGsmProtocol.LastError
WScript.Quit
End If
Set objSmsMessage = objGsmProtocol.GetFirstMessage() ' Get first message
While ( objGsmProtocol.LastError = 0 )
WScript.Echo "Message from: " & objSmsMessage.Sender ' Show sender's mobile number
wScript.Echo "Message : " & objSmsMessage.Data ' Show the SMS message text
Set objSmsMessage = objGsmProtocol.GetNextMessage() ' Get next message
Wend
Send a Unicode SMS message via GSM/GPRS Modem
Set objSmsMessage = CreateObject( "ActiveXperts.SmsMessage" ) ' Create SmsMessage instance
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" ) ' Create SmsProtocolGsm instance
Set objSmsConstants = CreateObject( "ActiveXperts.SmsConstants" ) ' Create SmsConstants instance
objSmsMessage.Recipient = "+31624896641" ' Recipient's mobile number
objSmsMessage.Format = objSmsConstants.asMESSAGFORMAT_UNICODE ' SMS message format
objSmsMessage.Data = "ملحق خاصملحق خاص" ' SMS message text
objGsmProtocol.Device = "MultiTech GSM MultiModem"
objGsmProtocol.EnterPin( "1234" ) ' SIM card's PIN code
objGsmProtocol.Send ( objSmsMessage ) ' Send the SMS message now
WScript.Echo "Result: " & objGsmProtocol.LastError
Send a Ringtone message via GSM/GPRS Modem
Set objSmsMessage = CreateObject( "ActiveXperts.SmsMessage") ' Create SmsMessage instance
Set objRingTone = CreateObject( "ActiveXperts.SmsDataRingtone" ) ' Create SmsDataRingtone instance
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" ) ' Create SmsProtocolGsm instance
Set objSmsConstants = CreateObject( "ActiveXperts.SmsConstants" ) ' Create SmsConstants instance
objRingtone.LoadRTTTL( "Muppets:d=4,o=5,b=250:c6,c6,a,b,8a,b,g,p,c6,c6,a,8b,8a,8p,g.,p,e,e,g,f,8e,f,8c6,8c,8d,e,8e,8e," & _
"8p,8e,g,2p,c6,c6,a,b,8a,b,g,p,c6,c6,a,8b,a,g.,p,e,e,g,f,8e,f,8c6,8c,8d,e,8e,d,8d,c" )
objRingtone.Encode ' Encode the message
If( objRingtone.LastError <> 0 ) Then
WScript.Echo "Error encoding ringtone: " & objRingtone.LastError
WScript.Quit
End If
objSmsMessage.Data = objRingtone.EncodedMessage ' Assign encoded data to the message
objSmsMessage.Format = objSmsConstants.asMESSAGEFORMAT_DATA_UDH
objSmsMessage.Recipient = "+31647134225"
objGsmProtocol.Device = "COM1"
objGsmProtocol.Send( objSmsMessage ) ' Send the ringtone
If ( objGsmProtocol.LastError <> 0 ) Then
WScript.Echo ( "Error " & objGsmProtocol.LastError & " : " & objGsmProtocol.GetErrorDescription ( objGsmProtocol.LastError ) )
WScript.Quit
End If
WScript.Echo "Message successfully submitted."
Send a WAP Push message (via SMPP)
Set objSmsMessage = CreateObject( "ActiveXperts.SmsMessage" ) ' Create SmsMessage instance
Set objWapPush = CreateObject( "ActiveXperts.SmsDataWapPush" ) ' Create SmsDataWapPush instance
Set objSmppProtocol = CreateObject( "ActiveXperts.SmsProtocolSmpp" ) ' Create SmsProtocolSmpp instance
Set objSmsConstants = CreateObject( "ActiveXperts.SmsConstants" ) ' Create SmsConstants instance
objWapPush.URL = "http://wap.yahoo.com" ' Push wap.yahoo.com
objWapPush.Description = "Go visit yahoo.com !" ' Friendly push text
objWapPush.Encode ' Encode the WAP data
objSmsMessage.Recipient = "+31647134225" ' Recipient's mobile number
objSmsMessage.Data = objWapPush.EncodedMessage ' Assign encoded data to the message
objSmsMessage.Format = objSmsConstants.asMESSAGEFORMAT_DATA_UDH
objSmppProtocol.Server = "smpp.activexperts-labs.com" ' SMPP server (hostname or IP address)
objSmppProtocol.ServerPort = 2775 ' TCP/IP port of the SMPP server
objSmppProtocol.SystemID = "myaccount" ' SMPP server login
objSmppProtocol.SystemPassword = "mypassword" ' SMPP server password
objSmppProtocol.Connect
If objSmppProtocol.IsConnected = True Then
objSmppProtocol.Send( objSmsMessage ) ' Send WAP message
objSmppProtocol.Disconnect ' Disconnect
End If
Send a Voicemail indication (via GSM Modem / GSM phone)
Set objSmsMessage = CreateObject( "ActiveXperts.SmsMessage") ' Create SmsMessage instance
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" ) ' Create SmsProtocolGsm instance
Set objSmsConstants = CreateObject( "ActiveXperts.SmsConstants" ) ' Create SmsConstants instance
objSmsMessage.Recipient = "+31624896641" ' Recipient's mobile number
objSmsMessage.Data = "5" ' Indication for 5 new voicemail messages
objSmsMessage.Format = objSmsConstants.asMESSAGEFORMAT_INDICATION_VOICEMAIL ' Voicemail indication
objGsmProtocol.Device = "MultiTech GSM MultiModem"
objGsmProtocol.Send( objSmsMessage ) ' Send the voicemail indication now
WScript.Echo "Result: " & objGsmProtocol.LastError
4.2. SMS Hardware requirements
SmsProtocolGsm requirements: GSM/GPRS modem or GSM phone with datacable/bluetooth
This is a fast and reliable device to send and receive SMS messages.
You can send plain text SMS messages, unicode messages, ringtones and other advanced SMS messages using a GSM modem.
To send/receive SMS messages using a GSM modem, use the
SmsProtocolGsm object.
ActiveXperts recommends Falcom SAMBA GSM modems, WaveCom GSM modems and MultiTech GSM modems. For more information,
click here.
SmsProtocolSmpp requirements: Internet connection / VPN tunnel.
Customers requiring a high throughput should deliver SMS messsages over a network connection to a remote SMPP-compliant SMSC provider.
The SMPP ('Short Message Peer-to-Peer') protocol is a Layer-7 TCP/IP protocol for exchanging SMS messages between SMS peer entities such as short message service centres.
It is often used to allow third parties (e.g. content suppliers like news organisations) to submit SMS messages, often in bulk.
To send SMS messages using an SMPP-compliant provider and SMS and MMS Toolkit, use the
SmsProtocolSmpp object.
You can use the free ActiveXperts SMPP Demo server (smpp.activexperts-labs.com) to send and receive a limited number of SMPP messages (for testing only).
For daily use, you need to sign-up with a commercial SMPP-compliant SMSC provider.
For a list of SMPP providers that have been tested with ActiveXperts SMS and MMS Toolkit, click here:
www.activexperts.com/xmstoolkit/smpplist.
SmsProtocolHttp requirements: Internet connection / VPN tunnel.
With the easy-to-configure HTTP interface you can send SMS messages directly from your business applications or websites in minutes.
All you need is a subscription with a commercial HTTP- compliant SMS provider, and an internet connection.
To send SMS messages using an HTTP-compliant provider and SMS and MMS Toolkit, use the
SmsProtocolHttp object.
You can use the free ActiveXperts SMSHTTP gateway (post.activexperts-labs.com:8080) to send and receive a limited number of SMS/HTTP messages (for testing only).
For daily use, you need to sign-up with a commercial HTTP-compliant SMS provider.
SmsProtocolDialup requirements: Hayes compatible modems (1200 bps or higher)
Use SMS and MMS Toolkit connect your normal Hayes modem (1200 bps or higher) to an SMSC service provider and send out SMS messages, one-by-one.
There are many SMSC dial-in provider around the world. Most of them do not require sign-up. You pay per dial-up call.
For a complete list of SMSC dial-in providers around the world,
click here.
You can only send plain text messages with a normal modem; to send ringtones, data, unicode and other advanced SMS format,
you should use a GSM Modem (or GSM phone with modem functions). You cannot receive SMS messages using a normal Hayes modem.
To use a normal Hayes modem to connect to an SMSC dial-in provider with SMS and MMS Toolkit, use the
SmsProtocolDialup object.
4.2. Visual Basic .NET
Make sure the SMS and MMS Toolkit is installed on your system. For details about installation,
click here.
Add a reference to the object using the Visual Basic Solution Explorer:
-
Start the Solution Provider, go to the project's 'References' container;
-
Choose 'Add Reference' from the context menu;
-
Select the COM tab, choose the 'ActiveXperts SMS and MMS Toolkit' component.
You can create a new
SmsMessage object in the following way:
Imports AXmsCtrl
...
Dim objSmsMessage As SmsMessage = New SmsMessage()
You can create a new
SmsConstants object in the following way:
Imports AXmsCtrl
...
Dim objSmsConstants As SmsConstants = New SmsConstants()
If you use a GSM modem (or GSM phone) to send and/or receive SMS messages, create a new
SmsProtocolGsm object in the following way:
Imports AXmsCtrl
...
Dim objGsmProtocol As SmsProtocolGsm = New SmsProtocolGsm()
If you use an HTTP-compliant SMSC provider to deliver SMS messages, create a new
SmsProtocolHttp object in the following way:
Imports AXmsCtrl
...
Dim objHttpProtocol As SmsProtocolHttp = New SmsProtocolHttp()
If you use an SMPP-compliant SMSC provider to deliver messages, create a new
SmsProtocolSmpp object in the following way:
Imports AXmsCtrl
...
Dim objSmppProtocol As SmsProtocolSmpp = New SmsProtocolSmpp()
If you use a normal modem to connect to an SMSC dial-in provider, create a new
SmsProtocolDialup object in the following way:
Imports AXmsCtrl
...
Dim objDialupProtocol As SmsProtocolDialup = New SmsProtocolDialup()
If you want to use advanced SMS data objects, you can create a new
SmsDataWapPush, SmsDataWapBookmark, SmsDatavCard, SmsDataRingtone, SmsDataPicture or SmsDataMmsNotification object in the following way:
Imports AXmsCtrl
...
Dim objWapPush As SmsDataWapPush = New SmsDataWapPush()
Dim objWapBookmark As SmsDataWapBookmark = New SmsDataWapBookmark()
Dim objCard As SmsDatavCard = new SmsDatavCard()
Dim objRingtone As SmsDataRingtone = New SmsDataRingtone()
Dim objPictureMessage As SmsDataPicture = New SmsDataPicture()
Dim objNotification As SmsDataMmsNotification = New SmsDataMmsNotification()
After these declarations and creation of the object(s), you can use the objects in your Visual Basic .NET projects.
4.3. Visual C# .NET
Make sure the SMS and MMS Toolkit is installed on your system. For details about installation,
click here.
Add a reference to the object using the Visual C# Solution Explorer:
- Start the Solution Provider, go to the project's 'References' container;
- Choose 'Add Reference' from the context menu;
- From the COM components tab, choose the 'ActiveXperts SMS and MMS Toolkit' component.
You can create a new
SmsMessage object in the following way:
using AXmsCtrl;
...
SmsMessage objSmsMessage = new SmsMessage();
You can create a new
SmsConstants object in the following way:
using AXmsCtrl;
...
SmsConstants objSmsConstants = new SmsConstants();
If you use a GSM modem (or GSM phone) to send SMS messages, declare and create a new
SmsProtocolGsm object in the following way:
using AXmsCtrl;
...
SmsProtocolGsm objGsmProtocol = new SmsProtocolGsm();
If you use an HTTP-compliant SMSC provider to deliver messages, create a new
SmsProtocolHttp object in the following way:
using AXmsCtrl;
...
SmsProtocolHttp objHttpProtocol = new SmsProtocolHttp();
If you use an SMPP-compliant SMSC provider to deliver messages, create a new
SmsProtocolSmpp object in the following way:
using AXmsCtrl;
...
SmsProtocolSmpp objSmppProtocol = new SmsProtocolSmpp();
If you use a normal modem to connect to an SMSC dial-in provider, create a new
SmsProtocolDialup object in the following way:
using AXmsCtrl;
...
SmsProtocolDialup objDialupProtocol = new SmsProtocolDialup();
If you want to use advanced SMS data objects, you can create a new
SmsDataWapPush, SmsDataWapBookmark, SmsDatavCard, SmsDataRingtone, SmsDataPicture or SmsDataMmsNotification object in the following way:
using AXmsCtrl;
...
SmsDataWapPush objWapPush = new SmsDataWapPush();
SmsDataWapBookmark objWapBookmark = new SmsDataWapBookmark();
SmsDatavCard objCard = new SmsDatavCard();
SmsDataRingtone objRingtone = new SmsDataRingtone();
SmsDataPicture objPictureMessage = new SmsDataPicture();
SmsDataMmsNotification objNotification = new SmsDataMmsNotification();
After these declarations and creation of the object(s), you can use the
objects inside your Visual C# .NET code.
4.4. Visual Basic
Make sure the SMS and MMS Toolkit is installed on your system. For details about installation,
click here.
SMS and MMS Toolkit can be used in Visual Basic 5.x or higher. In Visual
Basic, go to the 'Project/References...' menu item and check the box next to
'ActiveXperts SMS and MMS Toolkit' Type Library. Now, you can declare and
create SMS objects.
You can create a new
SmsMessage object in the following way:
Dim objSmsMessage As AXmsCtrl.SmsMessage
Set objSmsMessage = CreateObject( "ActiveXperts.SmsMessage" )
You can create a new
SmsConstants object in the following way:
Dim objSmsConstants As AXmsCtrl.SmsConstants
Set objSmsConstants = CreateObject( "ActiveXperts.SmsConstants" )
If you use a GSM modem (or GSM phone) to send SMS messages, create a new
SmsProtocolGsm object using the 'CreateObject' function:
Dim objGsmProtocol As AXmsCtrl.SmsProtocolGsm
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" )
If you use an HTTP-compliant SMSC provider to deliver messages, create a new
SmsProtocolHttp object in the following way:
Dim objHttpProtocol As AXmsCtrl.SmsProtocolHttp
Set objHttpProtocol = CreateObject( "ActiveXperts.SmsProtocolHttp" )
If you use an SMPP-compliant SMSC provider to deliver messages, create a new
SmsProtocolSmpp object in the following way:
Dim objSmppProtocol As AXmsCtrl.SmsProtocolSmpp
Set objSmppProtocol = CreateObject( "ActiveXperts.SmsProtocolSmpp" )
If you use a normal modem to connect to an SMSC dial-in provider, create a new
SmsProtocolDialup object using the 'CreateObject' function:
Dim objDialupProtocol As AXmsCtrl.SmsProtocolDialup
Set objDialupProtocol = CreateObject( "ActiveXperts.SmsProtocolDialup" )
If you want to use advanced SMS data objects, you can create a new
SmsDataWapPush, SmsDataWapBookmark, SmsDatavCard, SmsDataRingtone, SmsDataPicture or SmsDataMmsNotification object in the following way:
Dim objWapPush As AXmsCtrl.SmsDataWapPush
Set objWapPush = CreateObject( "ActiveXperts.SmsDataWapPush" )
Dim objWapBookmark As AXmsCtrl.SmsDataWapBookmark
Set objWapBookmark = CreateObject( "ActiveXperts.SmsDataWapBookmark" )
Dim objCard As AXmsCtrl.SmsDatavCard
Set objCard = CreateObject ( "ActiveXperts.SmsDatavCard" )
Dim objRingtone As AXmsCtrl.SmsDataRingtone
Set objRingtone = CreateObject( "ActiveXperts.SmsDataRingtone" )
Dim objPictureMessage As AXmsCtrl.SmsDataPicture
Set objPictureMessage = CreateObject( "ActiveXperts.SmsDataPicture" )
Dim objNotification As AXmsCtrl.SmsDataMmsNotification
Set objNotification = CreateObject( "ActiveXperts.SmsDataMmsNotification" )
After these declarations and creation of the object(s), you can use the objects in your Visual Basic projects.
4.5. Visual C++
Make sure the SMS and MMS Toolkit is installed on your system. For details about installation,
click here.
SMS and MMS Toolkit can be used in Visual C++ projects. Include the *.h and
*.c file provided by ActiveXperts to bind your code to the SMS component. These
files are located in the
Include directory of the Visual C++ samples
directory. These are the files:
- AXmsCtrl.h
- AXmsCtrl_i.c
- AXmsConstants.h
You can create a new
SmsMessage object in the following way:
ISmsMessage *pSmsMessage;
CoCreateInstance(CLSID_SmsMessage, NULL, CLSCTX_INPROC_SERVER, IID_ISmsMessage, (void**) &pSmsMessage);
If you use a GSM modem (or GSM phone) to send and/or receive SMS messages, declare and create a new
SmsProtocolGsm object in the following way:
ISmsProtocolGsm *pGsmProtocol;
CoCreateInstance(CLSID_SmsProtocolGsm, NULL, CLSCTX_INPROC_SERVER, IID_ISmsProtocolGsm, (void**) &pGsmProtocol);
If you use an HTTP-compliant SMSC provider to deliver messages, create a new
SmsProtocolHttp object in the following way:
ISmsProtocolHttp *pHttpProtocol;
CoCreateInstance(CLSID_SmsProtocolHttp, NULL, CLSCTX_INPROC_SERVER, IID_ISmsProtocolHttp, (void**) &pHttpProtocol);
If you use an SMPP-compliant SMSC provider to deliver messages, create a new
SmsProtocolSmpp object in the following way:
ISmsProtocolSmpp *pSmppProtocol;
CoCreateInstance(CLSID_Smpp, NULL, CLSCTX_INPROC_SERVER, IID_ISmsProtocolSmpp, (void**) &pSmppProtocol);
If you use a normal modem to connect to an SMSC dial-in provider, declare and create a new
SmsProtocolDialup object in the following way:
way:
ISmsProtocolDialup *pDialupProtocol;
CoCreateInstance(CLSID_SmsProtocolDialup, NULL, CLSCTX_INPROC_SERVER, IID_ISmsProtocolDialup, (void**) &pDialupProtocol);
To format SMS messages as WAP Push or WAP Bookmark messages, you can create a new
SmsDataWapPush or SmsDataWapBookmark object in the following way:
ISmsDataWapPush *pObjWapPush;
CoCreateInstance(CLSID_SmsDataWapPush, NULL, CLSCTX_INPROC_SERVER, IID_ISmsDataWapPush, (void**) &pObjWapPush);
IWapBookmark *pObjWapBookmark;
CoCreateInstance(CLSID_SmsDataWapBookmark, NULL, CLSCTX_INPROC_SERVER, IID_ISmsDataWapBookmark, (void**) &pObjWapBookmark);
To format SMS messages as vCard, you can create a new
SmsDatavCard object in the following way:
ISmsDatavCard *pObjCard;
CoCreateInstance(CLSID_SmsDatavCard, NULL, CLSCTX_INPROC_SERVER, IID_ISmsDatavCard, (void**) &pObjCard);
If you want to use advanced SMS data objects, you can create a new
SmsDataWapPush, SmsDataWapBookmark, SmsDataRingtone, SmsDataPicture or SmsDataMmsNotification object in the following way:
ISmsDataRingtone *pObjRingtone;
CoCreateInstance(CLSID_SmsDataRingtone, NULL, CLSCTX_INPROC_SERVER, IID_ISmsDataRingtone, (void**) &pObjRingtone);
ISmsDataPictureMessage *pObjPictureMessage;
CoCreateInstance(CLSID_SmsDataPicture, NULL, CLSCTX_INPROC_SERVER, IID_ISmsDataPicture, (void**) &pObjPictureMessage);
To format SMS messages as MMS notification messages, you can create a new
SmsDataMmsNotification object in the following way:
ISmsDataMmsNotification *pNotification;
CoCreateInstance(CLSID_SmsDataMmsNotification, NULL, CLSCTX_INPROC_SERVER, IID_ISmsDataMmsNotification, (void**) &pObjNotification);
4.6. Delphi 6.x or higher
Make sure the SMS and MMS Toolkit is installed on your system.
For details about installation,
click here.
First, add a reference to the SMS and MMS Toolkit objects:
-
Go to Project->Import Type Library;
-
Select 'ActiveXperts SMS and MMS Toolkit Type Library';
-
Click 'Install';
-
The project 'dclusr.dpk' will be opened. Click 'Yes';
-
You can now use the ActiveXperts SMS and MMS Toolkit within your application by selecting the component from the 'ActiveX' component bar.
You can create a new
SmsMessage object in the following way:
SmsMessage : TSmsMessage; ' Declaration of the wrapper class
objSmsMessage : ISmsMessage; ' Declaration of the interface class
objSmsMessage := SmsMessage.DefaultInterface; ' Creation new instance of the object
You can create a new
SmsConstants object in the following way:
SmsConstants : TSmsConstants; ' Declaration of the wrapper class
objSmsConstants : ISmsConstants; ' Declaration of the interface class
objSmsConstants := SmsConstants.DefaultInterface; ' Creation new instance of the object
If you use a GSM modem (or GSM phone) to send SMS messages, create a new
SmsProtocolGsm object in the following way:
SmsProtocolGsm : TSmsProtocolGsm; ' Declaration of the wrapper class
objGsmProtocol : ISmsProtocolGsm; ' Declaration of the interface class
objGsmProtocol := SmsProtocolGsm.DefaultInterface; ' Creation new instance of the object
If you use an HTTP-compliant SMSC provider to deliver messages, create a new
SmsProtocolHttp object in the following way:
SmsProtocolHttp : TSmsProtocolHttp; ' Declaration of the wrapper class
objHttpProtocol : ISmsProtocolHttp; ' Declaration of the interface class
objHttpProtocol := SmsProtocolHttp.DefaultInterface; ' Creation new instance of the object
If you use an SMPP-compliant SMSC provider to deliver messages, create a new
SmsProtocolSmpp object in the following way:
SmsProtocolSmpp : TSmsProtocolSmpp; ' Declaration of the wrapper class
objSmppProtocol : ISmsProtocolSmpp; ' Declaration of the interface class
objSmppProtocol := SmsProtocolSmpp.DefaultInterface; ' Creation new instance of the object
If you use a normal modem to connect to an SMSC dial-in provider, create a new
SmsProtocolDialup object in the following way:
SmsProtocolDialup : TSmsProtocolDialup; ' Declaration of the wrapper class
objDialupProtocol : ISmsProtocolDialup; ' Declaration of the interface class
objDialupProtocol := SmsProtocolDialup.DefaultInterface; ' Creation new instance of the object
If you want to use advanced SMS data objects, you can create a new
SmsDataWapPush, SmsDataWapBookmark, SmsDataRingtone, SmsDataPicture or SmsDataMmsNotification object in the following way:
SmsDataWapPush : TSmsDataWapPush; ' Declaration of the wrapper class
objWapPush : ISmsDataWapPush; ' Declaration of the interface class
objWapPush := SmsDataWapPush.DefaultInterface; ' Creation new instance of the object
SmsDataWapBookmark : TSmsDataWapBookmark; ' Declaration of the wrapper class
objWapBookmark : ISmsDataWapBookmark; ' Declaration of the interface class
objWapBookmark := SmsDataWapBookmark.DefaultInterface; ' Creation new instance of the object
SmsDatavCard : TSmsDatavCard; ' Declaration of the wrapper class
objCard : ISmsDatavCard; ' Declaration of the interface class
objCard := SmsDatavCard.DefaultInterface; ' Creation new instance of the object
SmsDataRingtone : TSmsDataRingtone; ' Declaration of the wrapper class
objRingtone : ISmsDataRingtone; ' Declaration of the interface class
objRingtone := SmsDataRingtone.DefaultInterface; ' Creation new instance of the object
SmsDataPicture : TSmsDataPicture; ' Declaration of the wrapper class
objPictureMessage : ISmsDataPicture; ' Declaration of the interface class
objPictureMessage := SmsDataPicture.DefaultInterface; ' Creation new instance of the object
SmsDataMmsNotification : TSmsDataMmsNotification; ' Declaration of the wrapper class
objNotification : ISmsDataMmsNotification; ' Declaration of the interface class
objNotification := SmsDataMmsNotification.DefaultInterface; ' Creation new instance of the object
After these declarations and creation of the object(s), you can use the objects in your Delphi projects.
4.7. ASP 2.x environment
Simply create the objects in the following way:
<html>
<body>
Version:
<script language=vbscript runat=server>
Set objSmsConstants = CreateObject( "ActiveXperts.SmsConstants" )
Set objSmsMessage = CreateObject( "ActiveXperts.SmsMessage" )
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" )
Set objHttpProtocol = CreateObject( "ActiveXperts.SmsProtocolHttp" )
Set objSmppProtocol = CreateObject( "ActiveXperts.SmsProtocolSmpp" )
Set objDialupProtocol = CreateObject( "ActiveXperts.SmsProtocolDialup" )
Set objWapPush = CreateObject( "ActiveXperts.SmsDataWapPush" )
Set objWapBookmark = CreateObject( "ActiveXperts.SmsDataWapBookmark" )
Set objPictureMessage = CreateObject( "ActiveXperts.SmsDataPicture" )
Set objRingtone = CreateObject( "ActiveXperts.SmsDataRingtone" )
Set objCard = CreateObject( "ActiveXperts.SmsDatavCard" )
...
Set objMmsConstants = CreateObject( "ActiveXperts.MmsConstants" )
Set objMmsMessage = CreateObject( "ActiveXperts.MmsMessage" )
Set objMm1Protocol = CreateObject( "ActiveXperts.MmsProtocolMm1" )
Set objMm4Protocol = CreateObject( "ActiveXperts.MmsProtocolMm4" )
Set objMm7Protocol = CreateObject( "ActiveXperts.MmsProtocolMm7" )
...
Response.Write objGsmProtocol.Version
...
</script>
</body>
</html>
7. SmsProtocolGsm Object
7.1. SmsProtocolGsm Object - Introduction
The SmsProtocolGsm object enables sending and receiving of SMS messages using a GSM Modem or a modem-capable GSM phone.
The SmsProtocolGsm object communicates through a serial port, USB port, Bluetooth connection,
infrared port or any Windows telephony compliant device.
It is recommended to use Windows 'Phone and Modem' devices,
for example 'Standard 9600 bps Modem', or 'Nokia 6310i Phone'.
If a Windows telephony device is used, settings are controlled by the Windows
telephony driver, and can be configured through the 'Phone and Modem' settings:
- Open the Windows Control Panel from the Start menu;
- Double-click on 'Phone and Modem Options' and select the 'Modems' tab;
- Select the preferred modem and click on 'Properties'; from here, you can change the settings.
To select a 'Phone and Modem' device in the toolkit's object, assign an existing telephony name to the Device property:
- Device - the literal Windows telephony device string, for instance: 'Standard 9600 bps Modem'.
Alternatively, you can use a port directly, for instance: 'COM1'.
As a result, device properties must be setup properly before receiving messages:
- Device - The actual COM port, formatted as COMx, where x represents the COM port number;
- DeviceSpeed - The speed to be used to communicate with the GSM modem or GSM phone; default: 0 (which means that factory defaults are used for modem communications);
- DeviceInitString - The modem initialization string is used to initialize the modem; default value: '' (which means a generic initialization string will be used).
You can send different types of SMS messages:
- Text - Plain text (default)
- Flash - Plain text, immediate display
- Data - Data message (raw, 8 bits)
- Unicode - Unicode message
- Unicode Flash - Unicode message, immediate display
- WAP Push - Propagate a URL to the remote recipient's WAP phone
- WAP Bookmark - Propagate a bookmark to the remote recipient's WAP phone
- Indications - Voicemail indications, fax indications, e-mail indications
- Ringtones and pictures - RTTTL ringtones and BMP pictures
- MMS notification messages - Inform a user that a new MMS message is available for download
For more information about recommended GSM Modems,
click here.
For a list of GSM phones tested with SMS and MMS Toolkit,
click here.
Send a simple SMS message (via GSM Modem / GSM phone)
The following sample shows how to send an SMS message using a GSM modem (or modem-capable GSM phone):
Set objSmsMessage = CreateObject("ActiveXperts.SmsMessage") ' Create SmsMessage instance
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" ) ' Create SmsProtocolGsm instance
objSmsMessage.Recipient = "+4412345678" ' Recipient's mobile number
objSmsMessage.Data = "Hello, world!" ' SMS message text
objSmsMessage.RequestDeliveryStatus = False ' No request for status report
objSmsMessage.ValidityPeriod = 0 ' Use GSM operator's default retry time
objGsmProtocol.Device = "Nokia 6310i Modem" ' Use a Nokia Windows Telephony device
objGsmProtocol.EnterPin ( "1234" ) ' SIM card's PIN code
objGsmProtocol.Send( objSmsMessage )
If objGsmProtocol.LastError = 0 Then
WScript.Echo "Message successfully delivered."
Else
WScript.Echo "Error: " & objGsmProtocol.LastError
End If
NOTE: As an alternative, "Nokia 6310i Modem" can be replaced by "COM1", assuming that the Nokia phone is connected on COM1.
However, the use of Windows telephony devices is recommended.
Receive SMS messages using a GSM device
The following sample shows how to receive SMS messages via a GSM modem (or modem-capable GSM phone):
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" ) ' Create SmsProtocolGsm instance
Set objConstants = CreateObject( "ActiveXperts.SmsConstants" )
objGsmProtocol.Device = "Nokia 6310i Modem" ' Use a Nokia Windows Telephony device
objGsmProtocol.EnterPin( "1234" ) ' SIM card's PIN code
objGsmProtocol.MessageStorage = objConstants.asSTORAGE_ALL ' Receive from all available storage locations
numMessages = objGsmProtocol.Receive()
If ( objGsmProtocol.LastError <> 0 ) Then
WScript.Quit
End If
For i = 0 to numMessages - 1
On Error Resume Next
Set objSmsMessage = objGsmProtocol.GetMessage ( i ) ' Iterate over all received messages
On Error Goto 0
If( objGsmProtocol.LastError = 0 ) Then
WScript.Echo "Message from: " & objSmsMessage.Sender
WScript.Echo " " & objSmsMessage.Data
End If
Next
objGsmProtocol.DeleteAllMessages () ' Delete messages from phone or modem
7.2. SmsProtocolGsm Object - Overview of Properties and Functions
| Property |
Type |
In/Out |
Mand/Opt |
Description |
| Version |
String |
Out |
n/a |
Product version number |
| ExpirationDate |
String |
Out |
n/a |
Product expiration date |
| Device |
String |
In/Out |
M |
Name of the device you want to use for receiving the SMS messages |
| DeviceSpeed |
Number |
In/Out |
O |
The baudrate of the communication session |
| DeviceFlowControl |
Number |
In/Out |
O |
Hardware flow control |
| DeviceInitString |
String |
In/Out |
O |
Initialization string for the device |
| MessageStorage |
Number |
In/Out |
O |
Preferred message storage |
| ReportsStorage |
Number |
In/Out |
O |
Preferred report storage |
| SMSC |
String |
In/Out |
O |
Preferred SMSC centre |
| LastError |
Number |
Out |
n/a |
Result of the last called function |
| LogFile |
String |
In/Out |
O |
All GSM commands and responses are logged to this file |
|
| Function |
Description |
| Activate |
Activate the product |
| Clear |
Clear all properties |
| GetDeviceCount |
Return the number of Windows telephony devices installed on the local
computer |
| GetDevice |
Retrieve a Windows telephony device name |
| EnterPin |
Enter pincode (required if SIM card is pin protected) |
| Send |
Send an SMS message |
| SendCommand |
Send a special command to the GSM device and read the response |
| QueryStatus |
Query message status |
| Receive |
Read all SMS messages from device storage |
| GetMessage |
Get the message at a specified index |
| DeleteMessage |
Delete the message at a specified index |
| DeleteAllMessages |
Delete all SMS messages |
| GetErrorDescription |
Lookup error description of the given error code |
|
7.3. SmsProtocolGsm Object - Properties
Version property
Type:
String
Description:
Version information of SMS and MMS Toolkit. This property is read-only; you
cannot assign a value to it.
Example:
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" )
WScript.Echo "Version: " & objGsmProtocol.Version
ExpirationDate property
Type:
String
Description:
Expiration date of SMS and MMS Toolkit. This property is read-only; you
cannot assign a value to it.
Once you have registered the product, the property holds the empty string value.
Example:
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" )
WScript.Echo "ExpirationDate: " & objGsmProtocol.ExpirationDate
Device property
Type:
String
Description:
The preferred device for sending and receiving SMS messages.
You can either use a Windows telephony device (recommended) or a physical COM port (directly).
Assign one of the following strings to the 'Device' property:
- A valid Windows telephony device name - this must be the literal name as it appears in Modems
tab of the Phone and Modems Options applet in the Control Panel. For
instance: "Standard 9600 bps Modem";
Use the GetDevice function to iterate over the installed Windows telephony devices;
-
A valid COM port string, formatted as COMx, where x is a valid
COM port number. When you assign the 'Device' property with a COM port string,
you bypass all Windows telephony intelligence, like dialing rules, port sharing and so on.
Windows telephony devices are highly recommended.
Example:
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" ) ' Create SmsProtocolGsm instance
objGsmProtocol.Device = "Standard 19200 bps Modem" ' Use a Windows telephony device (recommended)
Example:
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" ) ' Create SmsProtocolGsm instance
objGsmProtocol.Device = "COM2" ' Use a COM port directly
DeviceSpeed property
Type:
Number
Description:
By default, the speed settings are inherited from the Windows telephony
device, or (in case a direct COM port is used) the default COM settings are
used.
The default speed will usually suffice.
Use 0 to use the default baudrate, or you any valid baudrate value like: 1200, 2400, 4800, 9600, 14400, 19200, 38400, 56000, 57600, 115200, etc.
Example:
Set objGsmProtocol = CreateObject( "ActiveXperts.SmsProtocolGsm" ) ' Create SmsProtocolGsm instance
objGsmProtocol.Device = "Standard 19200 bps Modem"
objGsmProtocol.DeviceSpeed = 4800 ' This will overwrite the Windows telephony device speed
DeviceFlowControl property
Type:
Number
Description:
Hardware flow control regulates communication between computer and device
(usually a modem). There are two signals on the port for hardware flow control:
DTR (Data Terminal Ready) and RTS (Request To Send). If you enable hardware
flow control, computer and device will use both physical signals for flow
control. It's very uncommon to change these values for
modem communications. The 'DeviceFlowControl' will be ignored if the
Device is a Windows telephony device, because flow control is already defined in the
Windows telephony device properties (in the Windows Control Panel).
If a Windows telephony device is used (for instance: "Standard 19200 bps modem"), the
'DeviceFlowControl' property will be ignored because it is configured through the
Control Panel.
For a list of flowcontrol values, click here.
Example:
Set objGsmProtocol = CreateObject("ActiveXperts.SmsPro