共用方式為


DeliveryChannel.DeliveryChannelArguments Property

Gets the collection of delivery channel arguments for the delivery channel.

命名空間: Microsoft.SqlServer.Management.Nmo
組件: Microsoft.SqlServer.Smo (in microsoft.sqlserver.smo.dll)

語法

'宣告
Public ReadOnly Property DeliveryChannelArguments As DeliveryChannelArgumentCollection
public DeliveryChannelArgumentCollection DeliveryChannelArguments { get; }
public:
property DeliveryChannelArgumentCollection^ DeliveryChannelArguments {
    DeliveryChannelArgumentCollection^ get ();
}
/** @property */
public DeliveryChannelArgumentCollection get_DeliveryChannelArguments ()
public function get DeliveryChannelArguments () : DeliveryChannelArgumentCollection

屬性值

A DeliveryChannelArgumentCollection object containing the arguments for the delivery channel.

備註

Use the DeliveryChannelArgumentCollection and DeliveryChannelArgument objects to define the arguments for a delivery channel.

Delivery channel arguments supply information used to connect to or deliver notifications to a specific delivery channel. For examples of delivery channel arguments, see 定義 File 傳遞通道 and 定義 SMTP 傳遞通道.

範例

The following examples show how to define a delivery channel and its arguments:

// Define a delivery channel that uses the built-in File protocol
DeliveryChannel fileChannel = 
    new DeliveryChannel(myInstance, "FileChannel");
fileChannel.ProtocolName = "File";

// Define and add arguments for the file delivery channel
DeliveryChannelArgument fileNameArg = 
    new DeliveryChannelArgument(fileChannel, "FileName");
fileNameArg.Value = sampleDirectory + 
    @"\Notifications\FileNotifications.txt";
fileChannel.DeliveryChannelArguments.Add(fileNameArg);

// Add the file delivery channel to the instance
myInstance.DeliveryChannels.Add(fileChannel);
' Define a delivery channel using the built-in File protocol
Dim fileChannel As DeliveryChannel = _
    New DeliveryChannel(myInstance, "FileChannel")
fileChannel.ProtocolName = "File"

' Define and add arguments for the file delivery channel
Dim fileNameArg As DeliveryChannelArgument = _
    New DeliveryChannelArgument(fileChannel, "FileName")
fileNameArg.Value = sampleDirectory + _
    "\Notifications\FileNotifications.txt"
fileChannel.DeliveryChannelArguments.Add(fileNameArg)

' Add the file delivery channel to the instance
myInstance.DeliveryChannels.Add(fileChannel)

執行緒安全性

Any public static (Shared in Microsoft Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

平台

開發平台

如需受支援的平台清單,請參閱<安裝 SQL Server 2005 的硬體和軟體需求>。

目標平台

如需受支援的平台清單,請參閱<安裝 SQL Server 2005 的硬體和軟體需求>。

請參閱

參考

DeliveryChannel Class
DeliveryChannel Members
Microsoft.SqlServer.Management.Nmo Namespace

其他資源

定義傳遞通道
Arguments Element (ICF)