WebPartConnection in Elements.xml provisioned, but not working

Hello,

I have the following code at the bottom of my Elements.xml, which provisions a File (Page, with web parts on it)

			<WebPartConnection ID="myConnectionId1"
												 ProviderID="WPPathProvider"
												 ProviderConnectionPointID="DFWP Row Provider ID"
												 ConsumerID="WPPathConsumer"
												 ConsumerConnectionPointID="DFWP Parameter Consumer ID">
				<WebPartTransformer Assembly="Microsoft.SharePoint,Version=15.0.0.0,Culture=neutral,PublicKeyToken=71e9bce111e9429c" Namespace="Microsoft.SharePoint.WebPartPages">
					<![CDATA[<WebPartPages:TransformableFilterValuesToParametersTransformer ConsumerFieldNames="RootFolderCustomParam" ProviderFieldNames="LinkFilename" />]]>
				</WebPartTransformer>
			</WebPartConnection>

When the page with the web parts on it is provisioned, seems like the connection is provisioned also, because when I Edit the page, I see that the Connection context menus of the web parts point to each other. So, in the UI it seems like the connection works. However, the provider web part does not provide data to the consumer, until I click on the created connection and in its popup click 'Finish' (Not changing anything).

What could cause the connection to provision, but not work until I click Finish in the popup? Where is the actual connection stored? Content database? Secure store? How do I possibly export a connection I have configured in the UI? I can't find it with SharePoint 2013 Manager tool, SharePoint Designer tool or any other.

May 16th, 2015 5:52am

Hi Hristo,

Per my understanding, you might want to connect two web parts on a custom page by modifying the Elements.xml.

As a workaround, I suggest you connect the two web parts programmatically using C# with SharePoint Object Model instead.

Here is a demo about how to provision and connect two web parts programmatically for your reference:

http://ojasmaru.blogspot.in/2012/07/sharepoint-2010-programmatically.html

Thanks 

Patrick Liang

Free Windows Admin Tool Kit Click here and download it now
May 17th, 2015 10:21pm

Hi,

Unfortunately, not an option, it's a no-code sandbox solution.

Thanks,

Hristo

May 18th, 2015 1:20am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics