Print

eDoreczenia_DeleteMessage

The eDoreczenia_DeleteMessage() function deletes the selected message with all associated content (i.e. attachments and evidences) from the selected mailbox in e-Doręczenia system (PURDE/PUH service). Function execution does not affect the content of the message which has so far been saved in AMODIT.

Syntax

eDoreczenia_DeleteMessage(mailboxId, messageId);

Function arguments

  • mailboxId – (String) identifier of the mailbox that is registered in AMODIT. The mailbox must store (contain) the message to be deleted.
  • messageId – (String) identifier of the message (e-Delivery identifier) which determines the message to be deleted.

Return value

This eDoreczenia_DeleteMessage() function returns Object.
This complex object contains the following properties:

  • Success – returns True, if the operation succeeds;
  • CombinedErrorMessage – returns a description of an error in case of the operation failure.

Examples

Example 1

In this example the eDoreczenia_DeleteMessage() function will delete the given message from the chosen e-Delivery mailbox, which is registered in AMODIT as 'TestMailbox1′. The message to delete is selected by its id taken from the value in the field named [MessageId] on the case. A result of the function execution returned as complex object allows to check operation status (property: Success) and optionally obtain error message (property: CombinedErrorMessage).

_mailboxId="TestMailbox1";
_messageId=[MessageId];
result = eDoreczenia_DeleteMessage(_mailboxId, _messageId);
if (!result.Success)
{
  ShowMessage(1, result.CombinedErrorMessage);
}

 

Czy artykuł był pomocny?
0 na 5 gwiazdek
5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 0%
5
How can we improve this article?
How Can We Improve This Article?