Quicklinks
The St. Joseph College is a secondary school for students ranging in age from 12 to 19 years old. The college has 1500 students in 3 different locations.
All of the students as well as all of the teachers and their workstations are kept in a single Active Directory domain: 'STJOSEPH.DOM'. This Active Directory is not accessible through the internet. All of the students and teachers also have their e-mail addresses and mobile numbers defined in the Active Directory.
The Active Directory is used to find out which of the students or teachers need to be reached in the following cases:
Currently the St. Joseph College notifies the students and by manually sending each student and / or teachers an e-mail. They have an MS Excel sheet which contains a lot of the same student information that is kept in their Active Directory. As long as they keep their Excel sheet synchronized with their Active Directory information it is possible to, through an Excel macro, generate a list of e-mail addresses to send the notification to.
This manual system has some drawbacks:
The new system should alleviate all the drawbacks of the old system and improve on it in the following ways:
For their new system the IT department of the St. Joseph College decided to use the ActiveXperts SMS Messaging Server. They wrote their glue code to interface the SMS Messaging Server with their Active Directory database using Visual Basic 6. The application reads the Active Directory database and creates outgoing messages for the SMS Messaging Server. The SMS Messaging server sends out the SMS and E-mail messages.
Their VB6 based application uses the following components and techniques:
Figure 1. shows a screenshot of the application.
![]() |
The St. Joseph College runs ActiveXperts SMS Messaging Server on a Windows 2003 Server. This server is member of the STJOSEPH.DOM domain.
One of the requirements is throughput, it may not take more than 5 minutes to send out an SMS message to hundred students. This throughput cannot be achieved with a GSM Modem (a GSM can send out only 1 message per 5 seconds maximum). Therefore, St. Joseph College subscribed with an SMPP provider (Clickatell). It's throughput is around 10 messages/second.
ActiveXperts SMS Messaging Server is configured to use SMPP service of Clickatell. This was done in the following way:
The software department of the College wrote the application in Visual Basic 6. The application consists of one modal dialog with the following fields:
Option Explicit
Dim g_Constants, g_MessageDB
Private Sub BTN_COUNTSTUDENTS_Click()
On Error Resume Next
Dim objOU, numCount, objStudent
MousePointer = vbHourglass
Set objOU = GetObject(TXT_LDAPSTRING)
If (objOU Is Nothing) Then
MsgBox "Unable to access the OU on the specified Domain Controller.", vbCritical, _
"St. Joseph"
Else
numCount = 0
For Each objStudent In objOU
numCount = numCount + 1
Next
MsgBox "Number of students in selected OU: " & numCount, vbOKOnly, "St. Joseph"
Set objOU = Nothing
End If
MousePointer = vbDefault
End Sub
Private Sub BTN_SHOWSTUDENTS_Click()
On Error Resume Next
Dim objOU, strStudents, objStudent
MousePointer = vbHourglass
Set objOU = GetObject(TXT_LDAPSTRING)
If (objOU Is Nothing) Then
MsgBox "Unable to access the OU on the specified Domain Controller.", vbCritical, _
"St. Joseph"
Else
strStudents = ""
For Each objStudent In objOU
strStudents = strStudents & objStudent.Name & " (" & _
"Mobile:" & objStudent.Mobile & "; " & _
"E-mail:" & objStudent.Mail & ")" & vbCrLf
Next
MsgBox "Students in selected OU: " & vbCrLf & _
"============================" & vbCrLf & vbCrLf & _
strStudents, vbOKOnly, "St. Joseph"
Set objOU = Nothing
End If
MousePointer = vbDefault
End Sub
Private Sub BTN_SUBMIT_Click()
On Error Resume Next
Dim objOU, objStudent, objMessageOut, numSmsMessages, numEmailMessages
numSmsMessages = 0
numEmailMessages = 0
MousePointer = vbHourglass
Set objOU = GetObject(TXT_LDAPSTRING)
MousePointer = vbDefault
If (objOU Is Nothing) Then
MsgBox "Unable to access the OU on the specified Domain Controller.", vbCritical, _
"St. Joseph"
Else
For Each objStudent In objOU
If (RB_SENDSMS.Value <> 0 And objStudent.Mobile <> "") Then
Set objMessageOut = g_MessageDB.Create
If (g_MessageDB.LastError = 0) Then
objMessageOut.Direction = g_Constants.MESSAGEDIRECTION_OUT
objMessageOut.Type = g_Constants.MESSAGETYPE_SMS
objMessageOut.Status = g_Constants.MESSAGESTATUS_OUT_SCHEDULED
objMessageOut.To = objStudent.Mobile
objMessageOut.ChannelID = 0 ' First available SMS channel
objMessageOut.Body = TXT_MESSAGEBODY
objMessageOut.ScheduleTime = TXT_SCHEDULE
objMessageOut.Save
End If
numSmsMessages = numSmsMessages + 1
End If
If (RB_SENDEMAIL.Value <> 0 And objStudent.Mail <> "") Then
Set objMessageOut = g_MessageDB.Create
If (g_MessageDB.LastError = 0) Then
objMessageOut.Direction = g_Constants.MESSAGEDIRECTION_OUT
objMessageOut.Type = g_Constants.MESSAGETYPE_EMAIL
objMessageOut.Status = g_Constants.MESSAGESTATUS_OUT_SCHEDULED
objMessageOut.To = objStudent.Mail
objMessageOut.ChannelID = 0 ' First available SMS channel
objMessageOut.Body = TXT_MESSAGEBODY
objMessageOut.ScheduleTime = TXT_SCHEDULE
objMessageOut.Save
End If
numEmailMessages = numEmailMessages + 1
End If
Next
Set objOU = Nothing
End If
MousePointer = vbDefault
MsgBox "#SMS Messages created: " & numSmsMessages & vbCrLf & _
"#E-mail messages created: " & numEmailMessages, vbInformation, "St. Joseph"
End Sub
Private Sub Form_Load()
TXT_LDAPSTRING = "LDAP://dell04/ou=students,dc=activexperts,dc=dom"
Set g_Constants = CreateObject("Axsms-messaging-server.Constants")
Set g_MessageDB = CreateObject("Axsms-messaging-server.Messages")
RB_SENDSMS.Value = 1
RB_SENDEMAIL.Value = 0
TXT_MESSAGEBODY = "All lessons from teacher Mr. Jones are cancelled on " & Date
TXT_MESSAGESUBJECT = "Notification from St. Joseph College"
TXT_MESSAGESUBJECT.Enabled = False
TXT_SCHEDULE = "+0d0h5m"
End Sub
Private Sub RB_SENDEMAIL_Click()
If (RB_SENDEMAIL.Value <> 0) Then
TXT_MESSAGESUBJECT.Enabled = True
Else
TXT_MESSAGESUBJECT.Enabled = False
End If
End Sub