ContentsIndex
Example
vm_gsm_sms_get_message_id_list
void custom_sms_get_message_id_list_callback(vm_gsm_sms_callback_t* callback_data)
{
    vm_gsm_sms_query_message_callback_t* query_result;
    if(callback_data->action == VM_GSM_SMS_ACTION_QUERY)
    {
        if(callback_data->cause == VM_GSM_SMS_CAUSE_NO_ERROR)
        {
            if(!callback_data->action_data)
            {
                 vm_log_debug("SMS gets message id list action_data is NULL.");
                 return;
            }
            query_result = (vm_gsm_sms_query_message_callback_t*)callback_data->action_data;
            if(!query_result->message_id_list)
            {
                vm_log_debug("message_id_list == NULL.");
                return;
            }
            if(query_result->message_num <=0)
            {
               vm_log_debug("not find the message_id_list.");
            }
            vm_log_debug("message id list number is %d", query_result->message_num);

            // Uses the message_id_list to get message or delete message.
            vm_free(query_result->message_id_list);
        }
        else
        {
            vm_log_debug("Query message failed.");
        }
    }
}

void custom_sms_get_message_id_list_sample(void)
{
    vm_gsm_sms_query_t query_data_t;
    VMINT res = 0;
    query_data_t.sort_flag  = VM_GSM_SMS_SORT_TIMESTAMP;
    query_data_t.order_flag = VM_GSM_SMS_ORDER_ASCEND;
    query_data_t.status     = VM_GSM_SMS_STATUS_READ;
    res = vm_gsm_sms_get_message_id_list(&query_data_t,
                              custom_sms_get_message_id_list_callback, NULL);
    if(res != VM_GSM_SMS_RESULT_OK)
    {
        vm_log_debug("custom_sms_get_message_id_list_sample failed");
    }
}
Created with a commercial version of Doc-O-Matic. In order to make this message disappear you need to register this software. If you have problems registering this software please contact us at support@toolsfactory.com.