SMS-it support forum    


Welcome to the SMS-it support forum.
Before entering a query/request please search the forum to see if someone else has asked the question before.
Please feel also free to respond to queries from other users if you have experienced the same type of problem and found a solution to it. 
Our support team will monitor this forum and endeavour to provide answers to the queries posted.
Please make sure to post your query to the right forum as there is a separate forum for each application provided by MAW Software.

Show messages for: Last 7 days Last 30 days All (Digest of all)


Back to the forum

On Monday , the 06.02.2003, MAW Consulting wrote at 18:03:25 :

>Directly write to the messages.db

Steve,
Writing directly to the messages.db should be avoided unless you know what you are going :-)

In short:
The easiest way for you is to always start with an empty messages.DB. This
will not store the send/failed messages, but as you are mainly interested
in the command line sending, this is not a problem. So just delete the
messages.db
before you start.

Then submit your messages in the following way:
*********************************
[Index]
20030602172847000=#
[Defaults]
_Entries=1
[20030602172847000]
Recipient=[SMS:07912345]
Type=1
Sent=0
Folder=Outbox
NbrMsgLines=1
Message[0]=Hello World!
*********************************

The index is in the format yyyymmddhhnnssxxx and may be used to schedule a
message. For you just use an old date (ie 20000101000000xxx) with xxx being
an incrementing number for your messages.

The fields:

Recipient: SMS number
Type: 1 for text
Sent: Use 0 (unsent)
Folder: must be Outbox
NbrMsgLines: Set to 1
Message[0]= your text.

So if you need to queue three messages the file will become

*********************************
[Index]
20000000000000001=#
20000000000000002=#
20000000000000003=#

[Defaults]
_Entries=3
[20000000000000001]
Recipient=[SMS:07912345]
Type=1
Sent=0
Folder=Outbox
NbrMsgLines=1
Message[0]=First message
[20000000000000002]
Recipient=[SMS:07912345]
Type=1
Sent=0
Folder=Outbox
NbrMsgLines=1
Message[0]=Second message
[20000000000000003]
Recipient=[SMS:07912345]
Type=1
Sent=0
Folder=Outbox
NbrMsgLines=1
Message[0]=Third message
*********************************

Now if you start SMS-it! (without command line) it will start to send the
three messages.

The ugly part comes unfortunately now :-(
As you want to start the sending through the command line you need to use
the last message and send it as parameter to the command line. SMS-it
requires a valid message to be submitted, otherwise it will fail (and not
process the queued messages).

Hence to send the three messages of the example above create a messages.db
with the two first messages, and then submit the last message as command
line parameters to start the sending.
To check if the messages were sent you may either again check the
messages.db (Sent=2 means OK, Sent=3 is failed) or check the Return value
(see the help file under "command line" for more information).

OK ?

Sincerely,

Marc Wanderer







Post reply:

Name:
E-Mail:
Subject:
Message:
SPAM code displayed
next to this:

CGIForum (C) Markus Triska


Home to