![Quectel UG Series Command Manual Download Page 119](http://html.mh-extra.com/html/quectel/ug-series/ug-series_command-manual_772151119.webp)
UMTS/HSPA Module Series
WCDMA UGxx AT Commands Manual
WCDMA_UGxx_AT_Commands_Manual Confidential / Released 118 / 247
9.5. AT+CMGD Delete Message
AT+CMGD deletes a short message from the preferred message storage
<mem1>
location
<index>
. If
<delflag>
is presented and not set to 0, then the ME shall ignore
<index>
and follow the rules of
<delflag>
shown as below.
Parameter
Example
AT+CMGD=1
//Delete the message specified in
<index>=1
OK
AT+CMGD Delete Message
Test Command
AT+CMGD=?
Response
+CMGD:
(list of supported
<index>
s),(list of supported
<delflag>
s)
OK
Write Command
AT+CMGD=<index>[,<delflag>]
Response
TA deletes message from preferred message storage
<mem1>
location
<index>
.
OK
If error is related to ME functionality:
+CMS ERROR:<err>
Maximum Response Time
300ms.
Note: Operation of
<delflag>
depends on the storage of
deleted messages.
Reference
3GPP TS 27.005
<index>
Integer type, in the range of location numbers supported by the associated memory
<delflag>
0
Delete the message specified in
<index>
1
Delete all read messages from
<mem1>
storage, leaving unread messages and
stored mobile originated messages (whether sent or not) untouched
2
Delete all read messages from
<mem1>
storage and sent mobile originated
messages, leaving unread messages and unsent mobile originated messages
untouched
3
Delete all read messages from
<mem1>
storage, sent and unsent mobile
originated messages, leaving unread messages untouched
4
Delete all messages from
<mem1>
storage
Quectel
Confidential