AddDistributionListItem method

Use this method to create a new MQDistributionListItem object and associate it with the distribution list object. The queue name parameter is mandatory.

This method inserts a new distribution list item as the first item in an existing list. Specifically, this method creates the following configuration:

  • In the distribution list, it sets the FirstDistributionListItem property to point to the new distribution list item.
  • In the new distribution list item, it sets the following properties:

    • It sets the DistributionList property to point to the distribution list.
    • It sets the PreviousDistributionListItem property to null.
    • It sets the NextDistributionListItem property to point to the distribution list item that was previously first, or to null if there were no previous items in the list.

We cannot use this method to add a new item when the distribution list is open.

    Defined in:
    MQDistributionList class

Syntax: set distributionlistitem = MQDistributionList .AddDistributionListItem (QName$, QMgrName$)

    Parameters:

    QName$ String. Name of the IBM MQ queue.

    QMgrName$ String. Name of the IBM MQ queue manager.