Remarque
L’accès à cette page nécessite une autorisation. Vous pouvez essayer de vous connecter ou de modifier des répertoires.
L’accès à cette page nécessite une autorisation. Vous pouvez essayer de modifier des répertoires.
Initializes a new instance of the DeliveryChannelArgument class with a DeliveryChannel object and a name.
Espace de noms: Microsoft.SqlServer.Management.Nmo
Assembly: Microsoft.SqlServer.Smo (in microsoft.sqlserver.smo.dll)
Syntaxe
'Déclaration
Public Sub New ( _
deliveryChannel As DeliveryChannel, _
name As String _
)
public DeliveryChannelArgument (
DeliveryChannel deliveryChannel,
string name
)
public:
DeliveryChannelArgument (
DeliveryChannel^ deliveryChannel,
String^ name
)
public DeliveryChannelArgument (
DeliveryChannel deliveryChannel,
String name
)
public function DeliveryChannelArgument (
deliveryChannel : DeliveryChannel,
name : String
)
Paramètres
- deliveryChannel
The parent DeliveryChannel object for this argument.
name
A String of up to 255 characters specifying the argument name.You cannot change the name. To rename a delivery channel argument, you must remove the argument and then add a new argument that has the new name.
Notes
Delivery channel arguments are dependent on the delivery protocol. Each protocol has its own requirements. For information about the arguments required by standard delivery protocols, see Protocoles de remise standard.
Exemple
The following examples show how to define a file 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)
Plateformes
Plateformes de développement
Pour obtenir la liste des plateformes prises en charge, consultez Configuration matérielle et logicielle requise pour l'installation de SQL Server 2005.
Plateformes cibles
Pour obtenir la liste des plateformes prises en charge, consultez Configuration matérielle et logicielle requise pour l'installation de SQL Server 2005.
Voir aussi
Référence
DeliveryChannelArgument Class
DeliveryChannelArgument Members
Microsoft.SqlServer.Management.Nmo Namespace
Autres ressources
Définition des canaux de remise
Name Element for DeliveryChannel/Arguments/Argument (ICF)