Registering remote objects

Download: CsNETDll_v3.zip (57,3 Kb - Updated 22.07.2010.)

This page gives you information on how you can use C# to send/receive SMS messages. A C#.NET SMS demo project is provided with full source code, that illustrates how to connect to Ozeki NG - SMS Gateway. The demo project makes it possible to send/receive SMS messages using a GSM Modem or an IP SMS connection, such as SMPP, CIMD2 or UCP/EMI. In my previous article (How to send SMS messages from C# using an SQL database) I have explained how you can send/receive SMS messages from C# using databases. The information I present here is useful if you would like to Interface directly with the SMS gateway without a database server.

Introduction to the C# SMS API

The C# SMS API is a client software, that can be used to connect to Ozeki NG - SMS Gateway directly to send and receive SMS messages from any C#.NET application. The API can be used to connect locally or remotely (over a LAN or the Internet) to the SMS Gateway. The API provides a classic example on how to use the .NET TCP/IP networking to make two applications (Your application and the SMS Gateway) work together. It uses the advantages provided by IP connectivity to create a client-server model. The API comes with an example. The C# SMS example is a working GUI application that can be used to send and receive SMS messages to get information about delivery status (Figure 1).

example application
Figure 1. - Example application

How to use the C# SMS API

To use the C# SMS API you must have a working installation of Ozeki NG SMS Gateway in your system. To get a working installation, you need to follow the steps in the Ozeki SMS Gateway installation guide and the steps in the SMS quick start guide to verify if sending and receiving works.

After you have a working SMS gateway, you can download and extract the C# SMS client. Note, that Ozeki NG SMS Gateway does not necessary have to be installed on the same computer where your C# SMS application is running. You can have Ozeki NG SMS Gateway on one computer and you can use Visual Studio to build your C# SMS application on a different computer.

The C# SMS API reference

The C# SMS API provides methods that allow you to send various message types, such as WAP Push, Flash SMS, Ringtones, VCard, VCalendar, etc. It also has events that help you track your SMS messages. For example you can subscribe for a notification about when a message was delivered to the network and when a message was delivered to the handset. The C# SMS API can also be used to receive SMS messages. This gives you the option to create applications like SMS voting, quiz games, or stock market data querying quickly. A complete documentation of the C# SMS API is available on the following webpage:

C# SMS API Reference

Alternatively you might find the following guide useful:

How to send and receive SMS messages from C# using an SQL compatible database

How to specify the validity period for your messages

Ozeki NG SMS Gateway allows you to send SMS messages from various applications. If you use C# SMS API for sending messages, you can set the validity period for your messages. For specifying the validity period, please use the following parameter:

&vp=2021.07.26.+10%3A07%3A58

Please note that 2021.07.26.+10%3A07%3A58 is the Urlencoded form of 2021.07.26. 10:07:58 .

With the use of this parameter, you can send validity information to the service provider. Therefore, the service provider can set messages to be valid for the specified period.

More information