SPLimitedWebPartManager.SPConnectWebParts - Méthode (WebPart, ProviderConnectionPoint, WebPart, ConsumerConnectionPoint, WebPartTransformer)
Relie les deux points de connexion de composant WebPart à l'aide d'un transformateur de connexion.
Espace de noms : Microsoft.SharePoint.WebPartPages
Assembly : Microsoft.SharePoint (dans Microsoft.SharePoint.dll)
Syntaxe
'Déclaration
Public Function SPConnectWebParts ( _
provider As WebPart, _
providerConnectionPoint As ProviderConnectionPoint, _
consumer As WebPart, _
consumerConnectionPoint As ConsumerConnectionPoint, _
transformer As WebPartTransformer _
) As SPWebPartConnection
'Utilisation
Dim instance As SPLimitedWebPartManager
Dim provider As WebPart
Dim providerConnectionPoint As ProviderConnectionPoint
Dim consumer As WebPart
Dim consumerConnectionPoint As ConsumerConnectionPoint
Dim transformer As WebPartTransformer
Dim returnValue As SPWebPartConnection
returnValue = instance.SPConnectWebParts(provider, _
providerConnectionPoint, consumer, _
consumerConnectionPoint, transformer)
public SPWebPartConnection SPConnectWebParts(
WebPart provider,
ProviderConnectionPoint providerConnectionPoint,
WebPart consumer,
ConsumerConnectionPoint consumerConnectionPoint,
WebPartTransformer transformer
)
Paramètres
provider
Type : System.Web.UI.WebControls.WebParts.WebPartLe composant WebPart fournisseur.
providerConnectionPoint
Type : System.Web.UI.WebControls.WebParts.ProviderConnectionPointLe point de connexion fournisseur.
consumer
Type : System.Web.UI.WebControls.WebParts.WebPartLe composant WebPart consommateur.
consumerConnectionPoint
Type : System.Web.UI.WebControls.WebParts.ConsumerConnectionPointLe point de connexion consommateur.
transformer
Type : System.Web.UI.WebControls.WebParts.WebPartTransformerLe transformateur WebPart entre les points de connexion.
Valeur renvoyée
Type : Microsoft.SharePoint.WebPartPages.SPWebPartConnection
L'objet SPWebPartConnection pour les points de connexion connecté.
Exceptions
Exception | Condition |
---|---|
WebPartPageUserException | Le fournisseur ou le composant WebPart consommateur n'est pas sur la page. |
Voir aussi
Référence
SPLimitedWebPartManager classe